|
@@ -78,9 +78,12 @@ export class WindowHelper {
|
|
|
WindowHelper._windowClass = value;
|
|
|
if (WindowHelper._windowClass) {
|
|
|
let avoidArea = WindowHelper._windowClass.getWindowAvoidArea(window.AvoidAreaType.TYPE_NAVIGATION_INDICATOR);
|
|
|
- WindowHelper._bottomRectHeight = avoidArea.bottomRect.height
|
|
|
+ WindowHelper._bottomRectHeight = px2vp(avoidArea.bottomRect.height)
|
|
|
let avoidArea2 = WindowHelper._windowClass.getWindowAvoidArea(window.AvoidAreaType.TYPE_CUTOUT);
|
|
|
- WindowHelper._topRectHeight = avoidArea2.topRect.height
|
|
|
+ WindowHelper._topRectHeight = px2vp(avoidArea2.topRect.height)
|
|
|
+ let avoidArea3 = WindowHelper._windowClass.getWindowAvoidArea(window.AvoidAreaType.TYPE_SYSTEM);
|
|
|
+ const a = px2vp(avoidArea3.topRect.height)
|
|
|
+ WindowHelper._topRectHeight = a > WindowHelper._topRectHeight ? a : WindowHelper._topRectHeight
|
|
|
// console.log('=====>', WindowHelper._topRectHeight)
|
|
|
}
|
|
|
}
|
|
@@ -106,7 +109,7 @@ export class WindowHelper {
|
|
|
* @returns
|
|
|
*/
|
|
|
public static get topRectHeight(): number {
|
|
|
- return WindowHelper._isFullScreen?WindowHelper._topRectHeight:0
|
|
|
+ return WindowHelper._isFullScreen ? WindowHelper._topRectHeight : 0
|
|
|
}
|
|
|
|
|
|
|