diff --git a/entry/src/main/ets/entryability/EntryAbility.ets b/entry/src/main/ets/entryability/EntryAbility.ets index 949a08ecb6d07978bb6ed21a290a6d8630dfdb84..f3771632224732c26ea77d60e9af43798db5a456 100644 --- a/entry/src/main/ets/entryability/EntryAbility.ets +++ b/entry/src/main/ets/entryability/EntryAbility.ets @@ -139,5 +139,6 @@ export default class EntryAbility extends UIAbility { // Main window is destroyed, release UI related resources hilog.info(DOMAIN, 'testTag', '%{public}s', 'Ability onWindowStageDestroy'); } + // [EndExclude WindowSizeChange] } // [End WindowSizeChange] \ No newline at end of file diff --git a/entry/src/main/ets/pages/Index.ets b/entry/src/main/ets/pages/Index.ets index 9867354cbf3a6602a8d80f6aa094b62e170e6e78..fc1d943824f4dfbaf77ca2340330d407d15ef0a9 100644 --- a/entry/src/main/ets/pages/Index.ets +++ b/entry/src/main/ets/pages/Index.ets @@ -44,7 +44,6 @@ struct Index { 'ohos.permission.READ_IMAGEVIDEO', 'ohos.permission.WRITE_IMAGEVIDEO' ]; - // [Start Preview2] // [Start FoldStatusChange] // [Start SelectCamera2] onFoldStatusChange: (foldStatus: display.FoldStatus) => void = (foldStatus: display.FoldStatus) => { @@ -53,10 +52,8 @@ struct Index { // Determine the page layout that has entered half folded status and prohibit portrait orientation. if (this.widthBp === WidthBreakpoint.WIDTH_MD && (orientation === display.Orientation.LANDSCAPE || orientation === display.Orientation.LANDSCAPE_INVERTED)) { - // [StartExclude Preview2] this.isHalfFolded = true; this.windowUtil.setMainWindowOrientation(window.Orientation.LANDSCAPE); - // [EndExclude Preview2] this.cameraUtil.setHalfFoldedRect(this.windowUtil.getWindowSize()); } else { if (this.oldFoldStatus === display.FoldStatus.FOLD_STATUS_FOLDED) { @@ -69,12 +66,10 @@ struct Index { } return; } - // [StartExclude Preview2] // [StartExclude SelectCamera2] if (this.widthBp !== WidthBreakpoint.WIDTH_SM) { this.windowUtil.setMainWindowOrientation(window.Orientation.AUTO_ROTATION_RESTRICTED); } - // [EndExclude Preview2] // [EndExclude SelectCamera2] // Exit the half folded status page. if (this.isHalfFolded) { @@ -98,7 +93,6 @@ struct Index { // [EndExclude SelectCamera2] } // [End FoldStatusChange] - // [End Preview2] aboutToAppear(): void { display.on('foldStatusChange', this.onFoldStatusChange);