diff --git a/common/resources/src/main/resources/rawfile/editor.html b/common/resources/src/main/resources/rawfile/editor.html index 67cd2a0..4288cfb 100644 --- a/common/resources/src/main/resources/rawfile/editor.html +++ b/common/resources/src/main/resources/rawfile/editor.html @@ -19,15 +19,15 @@
diff --git a/common/resources/src/main/resources/rawfile/icon/picture_white.svg b/common/resources/src/main/resources/rawfile/icon/picture_white.svg new file mode 100644 index 0000000..1def639 --- /dev/null +++ b/common/resources/src/main/resources/rawfile/icon/picture_white.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/common/resources/src/main/resources/rawfile/icon/styles.svg b/common/resources/src/main/resources/rawfile/icon/styles.svg new file mode 100644 index 0000000..4fb5bb6 --- /dev/null +++ b/common/resources/src/main/resources/rawfile/icon/styles.svg @@ -0,0 +1,11 @@ + + + diff --git a/common/resources/src/main/resources/rawfile/icon/todo1.svg b/common/resources/src/main/resources/rawfile/icon/todo1.svg new file mode 100644 index 0000000..7778298 --- /dev/null +++ b/common/resources/src/main/resources/rawfile/icon/todo1.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/product/default/src/main/ets/MainAbility/MainAbility.ts b/product/default/src/main/ets/MainAbility/MainAbility.ts index 07704b5..e9a8efa 100644 --- a/product/default/src/main/ets/MainAbility/MainAbility.ts +++ b/product/default/src/main/ets/MainAbility/MainAbility.ts @@ -30,10 +30,14 @@ export default class MainAbility extends Ability { onCreate(want, launchParam) { // @ts-ignore - window.getLastWindow(this.context,(err,data)=>{ - let windowWidth = data.getWindowProperties().windowRect.width - LogUtil.info(this.Tag, " getLastWindow:" + windowWidth) - this.screenBreakPoints(windowWidth) + window.getLastWindow(this.context, (err, data) => { + if (data && data.getWindowProperties()) { + let windowWidth = data.getWindowProperties().windowRect.width + LogUtil.info(this.Tag, " getLastWindow:" + windowWidth) + this.screenBreakPoints(windowWidth) + } else { + LogUtil.info(this.Tag, "getWindowProperties error:" + JSON.stringify(err)) + } }) LogUtil.info(this.Tag, " onCreate, launchReason is " + launchParam.launchReason + ", deviceType" + deviceInfo.deviceType) if (deviceInfo.deviceType === 'phone' || deviceInfo.deviceType === 'default') { @@ -200,7 +204,7 @@ export default class MainAbility extends Ability { } } - screenBreakPoints(data){ + screenBreakPoints(data) { let displayClass = null let screenDpi = null displayClass = display.getDefaultDisplaySync()