From c918dfea1b6574cd26844e1702e123ed822e5c8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E5=B0=8F=E7=A7=8B?= <1273378004@qq.com> Date: Wed, 7 Jul 2021 06:18:06 +0000 Subject: [PATCH 1/4] update changelog.md --- changelog.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/changelog.md b/changelog.md index 6306333..ad7984b 100644 --- a/changelog.md +++ b/changelog.md @@ -1,4 +1,4 @@ -## v1.0.0 +## 1.0.0 已支持部分: -- Gitee From e546048056bc932451e01504e4f56ea44eda7a26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E5=B0=8F=E7=A7=8B?= <1273378004@qq.com> Date: Wed, 15 Sep 2021 14:48:31 +0800 Subject: [PATCH 2/4] =?UTF-8?q?fix:=E9=A1=B9=E7=9B=AE=E5=B7=A5=E7=A8=8B?= =?UTF-8?q?=E9=80=82=E9=85=8D=E6=9C=80=E6=96=B0=E7=9A=84IDE=EF=BC=882.2.0.?= =?UTF-8?q?200=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build.gradle | 4 +-- entry/src/main/config.json | 23 ++++++------- .../main/resources/base/element/string.json | 32 +++++++++++++++++-- 3 files changed, 42 insertions(+), 17 deletions(-) diff --git a/build.gradle b/build.gradle index 8daf577..c66b1cc 100644 --- a/build.gradle +++ b/build.gradle @@ -19,8 +19,8 @@ buildscript { jcenter() } dependencies { - classpath 'com.huawei.ohos:hap:2.4.2.7' // 此处的插件版本应该改为你的IDE新建项目中自动生成的插件版本 - classpath 'com.huawei.ohos:decctest:1.0.0.6' + classpath 'com.huawei.ohos:hap:2.4.5.0' // 此处的插件版本应该改为你的IDE新建项目中自动生成的插件版本 + classpath 'com.huawei.ohos:decctest:1.2.4.1' } } diff --git a/entry/src/main/config.json b/entry/src/main/config.json index ef8ae55..e2b0ffb 100644 --- a/entry/src/main/config.json +++ b/entry/src/main/config.json @@ -6,10 +6,6 @@ "version": { "code": 1, "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5 } }, "deviceConfig": {}, @@ -41,13 +37,14 @@ "icon": "$media:icon", "label": "$string:app_name", "type": "page", - "launchType": "standard" + "launchType": "standard", + "visible": true }, { "orientation": "unspecified", "name": "me.majiajie.pagerbottomtabstriptest.MaterialDesignActivity", "icon": "$media:icon", - "label": "MaterialDesign", + "label": "$string:str_MaterialDesign", "type": "page", "launchType": "standard" }, @@ -55,7 +52,7 @@ "orientation": "unspecified", "name": "me.majiajie.pagerbottomtabstriptest.CustomAbility", "icon": "$media:icon", - "label": "Custom", + "label": "$string:str_Custom", "type": "page", "launchType": "standard" }, @@ -63,7 +60,7 @@ "orientation": "unspecified", "name": "me.majiajie.pagerbottomtabstriptest.Custom2Ability", "icon": "$media:icon", - "label": "Custom2", + "label": "$string:str_Custom2", "type": "page", "launchType": "standard" }, @@ -71,7 +68,7 @@ "orientation": "unspecified", "name": "me.majiajie.pagerbottomtabstriptest.HideAbility", "icon": "$media:icon", - "label": "Hide", + "label": "$string:str_Hide", "type": "page", "launchType": "standard" }, @@ -79,7 +76,7 @@ "orientation": "unspecified", "name": "me.majiajie.pagerbottomtabstriptest.SpecialAbility", "icon": "$media:icon", - "label": "Special", + "label": "$string:str_Special", "type": "page", "launchType": "standard" }, @@ -87,7 +84,7 @@ "orientation": "unspecified", "name": "me.majiajie.pagerbottomtabstriptest.VerticalAbility", "icon": "$media:icon", - "label": "Vertical", + "label": "$string:str_Vertical", "type": "page", "launchType": "standard" }, @@ -95,7 +92,7 @@ "orientation": "unspecified", "name": "me.majiajie.pagerbottomtabstriptest.VerticalCustomAbility", "icon": "$media:icon", - "label": "VerticalCustom", + "label": "$string:str_VerticalCustom", "type": "page", "launchType": "standard" }, @@ -103,7 +100,7 @@ "orientation": "unspecified", "name": "me.majiajie.pagerbottomtabstriptest.TestControllerAbility", "icon": "$media:icon", - "label": "TestController", + "label": "$string:str_TestController", "type": "page", "launchType": "standard" } diff --git a/entry/src/main/resources/base/element/string.json b/entry/src/main/resources/base/element/string.json index dd15a3a..9818370 100644 --- a/entry/src/main/resources/base/element/string.json +++ b/entry/src/main/resources/base/element/string.json @@ -5,8 +5,36 @@ "value": "PagerBottomTabStrip" }, { - "name": "materialdesignactivity_description", - "value": "hap sample empty provider" + "name": "str_MaterialDesign", + "value": "MaterialDesign" + }, + { + "name": "str_Custom", + "value": "Custom" + }, + { + "name": "str_Custom2", + "value": "Custom" + }, + { + "name": "str_Hide", + "value": "Hide" + }, + { + "name": "str_Special", + "value": "Special" + }, + { + "name": "str_Vertical", + "value": "Vertical" + }, + { + "name": "str_VerticalCustom", + "value": "VerticalCustom" + }, + { + "name": "str_TestController", + "value": "TestController" } ] } \ No newline at end of file -- Gitee From eeb04d71e8c4ec2921dee1b82d44a5234c92b11f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E5=B0=8F=E7=A7=8B?= <1273378004@qq.com> Date: Wed, 15 Sep 2021 14:55:28 +0800 Subject: [PATCH 3/4] =?UTF-8?q?fix=EF=BC=9A=E4=BF=AE=E5=A4=8D=E6=B0=B4?= =?UTF-8?q?=E6=B3=A2=E7=BA=B9=E7=82=B9=E5=87=BB=E8=BF=87=E5=BF=AB=E6=97=B6?= =?UTF-8?q?=E4=BC=9A=E5=AF=BC=E8=87=B4=E6=B0=B4=E6=B3=A2=E7=BA=B9=E5=8A=A8?= =?UTF-8?q?=E7=94=BB=E5=8D=A1=E4=BD=8F=EF=BC=8C=E7=84=B6=E5=90=8E=E7=BB=98?= =?UTF-8?q?=E5=88=B6=E5=BC=82=E5=B8=B8=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pagerbottomtabstrip/internal/MaterialItemLayout.java | 5 ++++- .../me/majiajie/pagerbottomtabstrip/widget/RippleLayout.java | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/pager-bottom-tab-strip/src/main/java/me/majiajie/pagerbottomtabstrip/internal/MaterialItemLayout.java b/pager-bottom-tab-strip/src/main/java/me/majiajie/pagerbottomtabstrip/internal/MaterialItemLayout.java index 7bfaf8a..631216d 100644 --- a/pager-bottom-tab-strip/src/main/java/me/majiajie/pagerbottomtabstrip/internal/MaterialItemLayout.java +++ b/pager-bottom-tab-strip/src/main/java/me/majiajie/pagerbottomtabstrip/internal/MaterialItemLayout.java @@ -266,12 +266,13 @@ public class MaterialItemLayout extends ComponentContainer implements ItemContro while (iterator.hasNext()) { Oval oval = iterator.next(); mPaint.setColor(new Color(oval.color)); - if (oval.radius < oval.maxR) { + if (oval.radius < oval.maxR && (oval.radius != oval.lastRadius)) { mTempRectF.left = oval.getLeft(); mTempRectF.top = oval.getTop(); mTempRectF.right = oval.getRight(); mTempRectF.bottom = oval.getBottom(); canvas.drawOval(mTempRectF, mPaint); + oval.lastRadius = oval.radius; } else { this.setBackground(ElementUtil.getShapeElementWith6(oval.color)); canvas.drawRect(0, 0, width, height, mPaint); @@ -525,12 +526,14 @@ public class MaterialItemLayout extends ComponentContainer implements ItemContro float centerX; float centerY; float maxR; + float lastRadius; Oval(int color, float radius, float centerX, float centerY) { this.color = color; this.radius = radius; this.centerX = centerX; this.centerY = centerY; + this.lastRadius = -1; } float getLeft() { diff --git a/pager-bottom-tab-strip/src/main/java/me/majiajie/pagerbottomtabstrip/widget/RippleLayout.java b/pager-bottom-tab-strip/src/main/java/me/majiajie/pagerbottomtabstrip/widget/RippleLayout.java index 03be398..bfef028 100644 --- a/pager-bottom-tab-strip/src/main/java/me/majiajie/pagerbottomtabstrip/widget/RippleLayout.java +++ b/pager-bottom-tab-strip/src/main/java/me/majiajie/pagerbottomtabstrip/widget/RippleLayout.java @@ -127,8 +127,9 @@ public class RippleLayout extends DependentLayout implements Component.EstimateS Iterator iterator = mOvals.iterator(); while (iterator.hasNext()) { Oval oval = iterator.next(); - if (oval.radius < getMaxRadius(oval.centerX, oval.centerY)) { + if (oval.radius < getMaxRadius(oval.centerX, oval.centerY) && (oval.radius != oval.lastRadius)) { canvas.drawOval(new RectFloat(oval.getLeft(), oval.getTop(), oval.getRight(), oval.getBottom()), mPaint); + oval.lastRadius = oval.radius; } else { canvas.drawRect(0, 0, width, height, mPaint); iterator.remove(); @@ -184,11 +185,13 @@ public class RippleLayout extends DependentLayout implements Component.EstimateS float radius; float centerX; float centerY; + float lastRadius; Oval(float radius, float centerX, float centerY) { this.radius = radius; this.centerX = centerX; this.centerY = centerY; + this.lastRadius = -1; } float getLeft() { -- Gitee From afc8aa65a8346d99750ec2aa42b704ff34d04f04 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E5=B0=8F=E7=A7=8B?= <1273378004@qq.com> Date: Wed, 15 Sep 2021 15:06:25 +0800 Subject: [PATCH 4/4] =?UTF-8?q?docs=EF=BC=9Amaven=E5=92=8Chapm=E5=8F=91?= =?UTF-8?q?=E5=B8=831.0.1=E7=89=88=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- changelog.md | 3 +++ pager-bottom-tab-strip/src/main/config.json | 5 ----- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index bba8180..8764f05 100644 --- a/README.md +++ b/README.md @@ -45,7 +45,7 @@ allprojects { mavenCentral() } } -implementation 'io.openharmony.tpc.thirdlib:PagerBottomTabStrip:1.0.0' +implementation 'io.openharmony.tpc.thirdlib:PagerBottomTabStrip:1.0.1' ``` ## 用法 diff --git a/changelog.md b/changelog.md index ad7984b..1c912c7 100644 --- a/changelog.md +++ b/changelog.md @@ -1,3 +1,6 @@ +## 1.0.1 +修复水波纹点击过快时会导致水波纹动画卡住,然后绘制异常的问题 + ## 1.0.0 已支持部分: diff --git a/pager-bottom-tab-strip/src/main/config.json b/pager-bottom-tab-strip/src/main/config.json index 59118f2..93ab924 100644 --- a/pager-bottom-tab-strip/src/main/config.json +++ b/pager-bottom-tab-strip/src/main/config.json @@ -5,11 +5,6 @@ "version": { "code": 1, "name": "1.0" - }, - "apiVersion": { - "compatible": 5, - "target": 5, - "releaseType": "Beta1" } }, "deviceConfig": {}, -- Gitee