From d214d8ac04a3a71cba689ea674e297bb075a4901 Mon Sep 17 00:00:00 2001 From: oh_ci Date: Wed, 20 Nov 2024 12:34:15 +0000 Subject: [PATCH] =?UTF-8?q?=E5=9B=9E=E9=80=80=20'Pull=20Request=20!4947=20?= =?UTF-8?q?:=20=E3=80=90Sample=E3=80=91=E4=BF=AE=E6=94=B9=E6=97=B6?= =?UTF-8?q?=E9=92=9F=E5=86=85=E5=AD=98=E5=9B=9E=E6=94=B6=E6=97=B6=E9=97=B4?= =?UTF-8?q?'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Tools/ArkTSClock/entry/src/main/ets/pages/Index.ets | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/Solutions/Tools/ArkTSClock/entry/src/main/ets/pages/Index.ets b/code/Solutions/Tools/ArkTSClock/entry/src/main/ets/pages/Index.ets index ec27c9398..8a807a491 100644 --- a/code/Solutions/Tools/ArkTSClock/entry/src/main/ets/pages/Index.ets +++ b/code/Solutions/Tools/ArkTSClock/entry/src/main/ets/pages/Index.ets @@ -19,7 +19,7 @@ import { forceGC } from '../util/ForceGCUtil'; const HOURS: Array = ['3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '1', '2'] const HEIGHT_ADD: number = 150 // 表盘下面需要绘制时间,canvas高度是宽度加150 const TAG: string = 'Index' -const DELAY: number = 7200000; +const DELAY: number = 600000; const UPDATE_DELAY: number = 1000; @Entry @@ -214,7 +214,7 @@ struct Clock { Logger.info(TAG, `onReady`) this.updateTime() this.intervalId = setInterval(this.updateTime, 1000) - this.intervalIdGC = setInterval(forceGC, DELAY); // 2小时GC一次 + this.intervalIdGC = setInterval(forceGC, DELAY); // 10分钟GC一次 }) } .width('100%') -- Gitee