From 5daa307c0c3708642fd81fe3bfeb3d1338813fdf Mon Sep 17 00:00:00 2001 From: wangtiantian Date: Fri, 9 Jul 2021 06:13:58 +0000 Subject: [PATCH] IssueNo:https://gitee.com/openharmony/graphic_ui/issues/I3ZW8W Description:fix uilabel bug Sig:graphic Feature or Bugfix:Bugfix Binary Source:No Signed-off-by: wangtiantian --- frameworks/components/ui_label.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/frameworks/components/ui_label.cpp b/frameworks/components/ui_label.cpp index a29d9c7..2649cf1 100755 --- a/frameworks/components/ui_label.cpp +++ b/frameworks/components/ui_label.cpp @@ -70,6 +70,9 @@ public: preRunTime_ = curTime; return; } + if (curTime == preRunTime_) { + return; + } uint32_t time = (curTime > preRunTime_) ? (curTime - preRunTime_) : (UINT32_MAX - preRunTime_ + curTime); // 1000: 1000 milliseconds is 1 second float floatStep = (static_cast(time * speed_) / 1000) + decimal_; -- GitLab