Description:JsEnvironment support timer.

Sig:SIG_ApplicationFramework
Feature or BugFix: Feature
Binary Source: No

Signed-off-by: zhangyafei.echo <zhangyafei12@huawei.com>
Change-Id: I1b74939ac8d8c47cc256edf016f611ab2754ed1a
This commit is contained in:
zhangyafei.echo
2023-04-26 19:23:13 +08:00
parent 446efeafd7
commit 331ac85bcb
10 changed files with 66 additions and 11 deletions
+7 -1
View File
@@ -515,7 +515,7 @@ bool JsRuntime::Initialize(const Options& options)
if (options.isUnique) {
HILOG_INFO("Not supported TimerModule when form render");
} else {
InitTimerModule(*nativeEngine, *globalObj);
InitTimerModule();
}
InitWorkerModule(*nativeEngine, codePath_, options.isDebugVersion, options.isBundle);
@@ -1075,5 +1075,11 @@ void JsRuntime::FreeNativeReference(std::unique_ptr<NativeReference> uniqueNativ
work = nullptr;
}
}
void JsRuntime::InitTimerModule()
{
CHECK_POINTER(jsEnv_);
jsEnv_->InitTimerModule();
}
} // namespace AbilityRuntime
} // namespace OHOS