From d79c764d30ce9e6a5aefe0a4b0e3d85bc401691a Mon Sep 17 00:00:00 2001 From: xujianhong Date: Tue, 25 May 2021 14:05:02 +0800 Subject: [PATCH 1/2] =?UTF-8?q?README=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- changeLog.md => CHANGELOG.md | 0 FloatingViewLib/build.gradle | 2 +- FloatingViewLib/src/main/config.json | 2 +- .../com/ufreedom/floatingview/ExampleTest.java | 15 +++++++++++++++ entry/build.gradle | 3 +++ .../demo}/ExampleOhosTest.java | 2 +- .../test/java/com/ufreedom/demo/ExampleTest.java | 16 +++++++++++++++- 7 files changed, 36 insertions(+), 4 deletions(-) rename changeLog.md => CHANGELOG.md (100%) rename entry/src/ohosTest/java/com/{ohoskun/xtablayout => ufreedom/demo}/ExampleOhosTest.java (97%) diff --git a/changeLog.md b/CHANGELOG.md similarity index 100% rename from changeLog.md rename to CHANGELOG.md diff --git a/FloatingViewLib/build.gradle b/FloatingViewLib/build.gradle index e3a8962..7c78a2c 100644 --- a/FloatingViewLib/build.gradle +++ b/FloatingViewLib/build.gradle @@ -1,6 +1,6 @@ apply plugin: 'com.huawei.ohos.library' ohos { - compileSdkVersion 5 + compileSdkVersion 4 defaultConfig { compatibleSdkVersion 5 } diff --git a/FloatingViewLib/src/main/config.json b/FloatingViewLib/src/main/config.json index fc27a92..70980bd 100644 --- a/FloatingViewLib/src/main/config.json +++ b/FloatingViewLib/src/main/config.json @@ -7,7 +7,7 @@ "name": "1.0" }, "apiVersion": { - "compatible": 5, + "compatible": 4, "target": 5, "releaseType": "Release" } diff --git a/FloatingViewLib/src/test/java/com/ufreedom/floatingview/ExampleTest.java b/FloatingViewLib/src/test/java/com/ufreedom/floatingview/ExampleTest.java index aa6cb47..12f2cb5 100644 --- a/FloatingViewLib/src/test/java/com/ufreedom/floatingview/ExampleTest.java +++ b/FloatingViewLib/src/test/java/com/ufreedom/floatingview/ExampleTest.java @@ -1,3 +1,18 @@ +/* + * Copyright (C) 2021 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain an copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package com.ufreedom.floatingview; import org.junit.Test; diff --git a/entry/build.gradle b/entry/build.gradle index 3ac9abb..c5cc2f4 100644 --- a/entry/build.gradle +++ b/entry/build.gradle @@ -13,3 +13,6 @@ dependencies { ohosTestImplementation 'com.huawei.ohos.testkit:runner:1.0.0.100' implementation('com.gitee.chinasoft_ohos:FloatingView:0.0.1-SNAPSHOT') } +decc { + supportType = ['html','xml'] +} diff --git a/entry/src/ohosTest/java/com/ohoskun/xtablayout/ExampleOhosTest.java b/entry/src/ohosTest/java/com/ufreedom/demo/ExampleOhosTest.java similarity index 97% rename from entry/src/ohosTest/java/com/ohoskun/xtablayout/ExampleOhosTest.java rename to entry/src/ohosTest/java/com/ufreedom/demo/ExampleOhosTest.java index dcee51a..daf7aaf 100644 --- a/entry/src/ohosTest/java/com/ohoskun/xtablayout/ExampleOhosTest.java +++ b/entry/src/ohosTest/java/com/ufreedom/demo/ExampleOhosTest.java @@ -13,7 +13,7 @@ * limitations under the License. */ -package com.ohoskun.xtablayout; +package com.ufreedom.demo; import ohos.aafwk.ability.delegation.AbilityDelegatorRegistry; import org.junit.Test; diff --git a/entry/src/test/java/com/ufreedom/demo/ExampleTest.java b/entry/src/test/java/com/ufreedom/demo/ExampleTest.java index 1920e18..a6ba95b 100644 --- a/entry/src/test/java/com/ufreedom/demo/ExampleTest.java +++ b/entry/src/test/java/com/ufreedom/demo/ExampleTest.java @@ -1,5 +1,19 @@ -package com.ufreedom.demo; +/* + * Copyright (C) 2021 Huawei Device Co., Ltd. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain an copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.ufreedom.demo; import org.junit.Test; /** -- Gitee From 85b01224be25c590f1d82062a4a2c1210fb09905 Mon Sep 17 00:00:00 2001 From: xujianhong Date: Tue, 25 May 2021 16:11:06 +0800 Subject: [PATCH 2/2] =?UTF-8?q?README=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 12 +++++------- README.md | 2 +- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4b5290c..3644375 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,5 @@ -# 基本功能:Component在别的Component上执行的漂浮动画 - -# 修改点: - 由于openharmony不支持Window.ID_ANDROID_CONTENT所以需要传递当前的Component在其上面进行操作 - -# 遗留问题(暂不支持的功能): - 无 \ No newline at end of file +## 0.0.1-SNAPSHOT +ohos 第一个版本 + * 实现了原库的大部分 api + * 由于openharmony不支持Window.ID_CONTENT所以需要传递当前的Component在其上面进行操作 + \ No newline at end of file diff --git a/README.md b/README.md index a313733..11feb4a 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ #### 调用差异说明 ```java - 由于openharmony无对应API Window.ID_ANDROID_CONTENT所以需要传递当前的顶层Component在其上面进行操作 + 由于openharmony无对应API Window.ID_CONTENT所以需要传递当前的顶层Component在其上面进行操作 所以在初始化Floating的时候需要传递当前的Component ``` #### 安装教程 -- Gitee