!33 截屏编码规范补充修改

Merge pull request !33 from 吕布布的耳朵/master
This commit is contained in:
openharmony_ci 2023-05-26 10:46:46 +00:00 committed by Gitee
commit 3eb3c40ba5
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -26,7 +26,7 @@ const ZOOM_RATIO = 0.4;
const WINDOW_Y = 300;
class ServiceExtAbility extends ServiceExtensionAbility {
onCreate(want) {
onCreate(want): void {
Log.showInfo(TAG, 'api8New onCreate, want:' + want.abilityName);
globalThis.shotScreenContext = this.context;
const windowConfig = {
@ -45,16 +45,16 @@ class ServiceExtAbility extends ServiceExtensionAbility {
win.setUIContent(INDEX_PAGE).then(() => {
ScreenShotModel.shotScreen();
Log.showInfo(TAG, 'then begin window loadContent in then! ');
})
})
})
});
});
});
}, (error) => {
Log.showInfo(TAG, 'window createFailed, error.code = ' + error.code);
})
});
Log.showInfo(TAG, 'after window create');
}
onDestroy() {
onDestroy(): void {
Log.showInfo(TAG, 'onDestroy');
}
}