!107 windowtype整改

Merge pull request !107 from fengwei/master
This commit is contained in:
openharmony_ci 2023-05-19 09:04:33 +00:00 committed by Gitee
commit 1cb1b384f3
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 2 additions and 2 deletions

View File

@ -73,7 +73,7 @@ class ServiceExtAbility extends ServiceExtension {
private createWindow(name: string) {
Log.showDebug(TAG, `createWindow name:${name}`)
windowManager.create(this.context, name, 2110).then((win) => {
windowManager.create(this.context, name, windowManager.WindowType.TYPE_KEYGUARD).then((win) => {
Log.showInfo(TAG, "before begin " + name + " window show!")
win.setPreferredOrientation(AUTO_ROTATION_RETRICTED, (err) => {
if (err.code) {

View File

@ -34,7 +34,7 @@ class ServiceExtAbility extends ServiceExtension {
private createWindow(name: string) {
Log.showDebug(TAG, `createWindow name:${name}`)
windowManager.create(this.context, name, 2110).then((win) => {
windowManager.create(this.context, name, windowManager.WindowType.TYPE_KEYGUARD).then((win) => {
win.loadContent("pages/index").then(() => {
Log.showInfo(TAG, name + " window loadContent in then! ")
win.show().then(() => {