From: Caisking <3449750381@qq.com> Date: Tue, 19 Dec 2023 11:34:28 +0000 (+0800) Subject: 释放动画资源 X-Git-Url: http://git.snicker.com.cn/Users/apple/Desktop/static/gitweb.css?a=commitdiff_plain;h=ad13fb80725cd2d4457a03b71bd402b790f549dd;p=mirrors%2FFD230.git 释放动画资源 --- diff --git a/code/sdk/application/wearable/nativeapp/nativeui/clock/src/MainClockView.cpp b/code/sdk/application/wearable/nativeapp/nativeui/clock/src/MainClockView.cpp index bb09d0fc3..7a5994956 100755 --- a/code/sdk/application/wearable/nativeapp/nativeui/clock/src/MainClockView.cpp +++ b/code/sdk/application/wearable/nativeapp/nativeui/clock/src/MainClockView.cpp @@ -86,6 +86,11 @@ MainClockView::~MainClockView() delete clockAnimator; clockAnimator = nullptr; } + if(progress1animator_ != nullptr) { + progress1animator_->Stop(); + delete progress1animator_; + progress1animator_ = nullptr; + } mainSweepClock->RemoveAll(); delete batteryLabel; @@ -564,7 +569,7 @@ bool MainClockView::InitView(void) return false; } progress1callback_ = new ProgressCallback(progress,batteryLabel); - progress1animator_ = new Animator(progress1callback_,progress,100,true); + progress1animator_ = new Animator(progress1callback_,progress,5000,true); progress1animator_->Start(); clockAnimator->Start(); SetCoverable(true);