diff --git a/zh-cn/application-dev/windowmanager/system-window-stage.md b/zh-cn/application-dev/windowmanager/system-window-stage.md index c45ead17e77c5860db8516663a7c14eb2a0cc26a..4cc4c98d56ad18cf9501124d401705031df4e558 100644 --- a/zh-cn/application-dev/windowmanager/system-window-stage.md +++ b/zh-cn/application-dev/windowmanager/system-window-stage.md @@ -47,14 +47,12 @@ import ExtensionContext from '@ohos.application.ServiceExtensionAbility'; import window from '@ohos.window'; -var windowClass = null; - export default class ServiceExtensionAbility1 extends ExtensionContext { onCreate(want) { console.log("[Demo] MainAbility onCreate") globalThis.abilityWant = want; // 1.创建音量条窗口。 - var windowClass = null; + let windowClass = null; window.create(this.context, "volume", window.WindowType.TYPE_VOLUME_OVERLAY, (err, data) => { if (err.code) { console.error('Failed to create the volume window. Cause:' + JSON.stringify(err));