Loading services/core/java/com/android/server/wm/ActivityRecord.java +1 −2 Original line number Diff line number Diff line Loading @@ -8942,8 +8942,7 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A : mDisplayContent.getDisplayInfo(); final Task task = getTask(); task.calculateInsetFrames(mTmpBounds /* outNonDecorBounds */, outStableBounds /* outStableBounds */, parentBounds /* bounds */, di, true /* useLegacyInsetsForStableBounds */); outStableBounds /* outStableBounds */, parentBounds /* bounds */, di); final int orientationWithInsets = outStableBounds.height() >= outStableBounds.width() ? ORIENTATION_PORTRAIT : ORIENTATION_LANDSCAPE; // If orientation does not match the orientation with insets applied, then a Loading services/core/java/com/android/server/wm/TaskFragment.java +3 −10 Original line number Diff line number Diff line Loading @@ -2331,8 +2331,7 @@ class TaskFragment extends WindowContainer<WindowContainer> { // area, i.e. the screen area without the system bars. // The non decor inset are areas that could never be removed in Honeycomb. See // {@link WindowManagerPolicy#getNonDecorInsetsLw}. calculateInsetFrames(mTmpNonDecorBounds, mTmpStableBounds, mTmpFullBounds, di, false /* useLegacyInsetsForStableBounds */); calculateInsetFrames(mTmpNonDecorBounds, mTmpStableBounds, mTmpFullBounds, di); } else { // Apply the given non-decor and stable insets to calculate the corresponding bounds // for screen size of configuration. Loading Loading @@ -2430,11 +2429,9 @@ class TaskFragment extends WindowContainer<WindowContainer> { * @param outNonDecorBounds where to place bounds with non-decor insets applied. * @param outStableBounds where to place bounds with stable insets applied. * @param bounds the bounds to inset. * @param useLegacyInsetsForStableBounds {@code true} if we need to use the legacy insets frame * for apps targeting U or before when calculating stable bounds. */ void calculateInsetFrames(Rect outNonDecorBounds, Rect outStableBounds, Rect bounds, DisplayInfo displayInfo, boolean useLegacyInsetsForStableBounds) { DisplayInfo displayInfo) { outNonDecorBounds.set(bounds); outStableBounds.set(bounds); if (mDisplayContent == null) { Loading @@ -2446,11 +2443,7 @@ class TaskFragment extends WindowContainer<WindowContainer> { final DisplayPolicy.DecorInsets.Info info = policy.getDecorInsetsInfo( displayInfo.rotation, displayInfo.logicalWidth, displayInfo.logicalHeight); intersectWithInsetsIfFits(outNonDecorBounds, mTmpBounds, info.mNonDecorInsets); if (!useLegacyInsetsForStableBounds) { intersectWithInsetsIfFits(outStableBounds, mTmpBounds, info.mConfigInsets); } else { intersectWithInsetsIfFits(outStableBounds, mTmpBounds, info.mOverrideConfigInsets); } } /** Loading Loading
services/core/java/com/android/server/wm/ActivityRecord.java +1 −2 Original line number Diff line number Diff line Loading @@ -8942,8 +8942,7 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A : mDisplayContent.getDisplayInfo(); final Task task = getTask(); task.calculateInsetFrames(mTmpBounds /* outNonDecorBounds */, outStableBounds /* outStableBounds */, parentBounds /* bounds */, di, true /* useLegacyInsetsForStableBounds */); outStableBounds /* outStableBounds */, parentBounds /* bounds */, di); final int orientationWithInsets = outStableBounds.height() >= outStableBounds.width() ? ORIENTATION_PORTRAIT : ORIENTATION_LANDSCAPE; // If orientation does not match the orientation with insets applied, then a Loading
services/core/java/com/android/server/wm/TaskFragment.java +3 −10 Original line number Diff line number Diff line Loading @@ -2331,8 +2331,7 @@ class TaskFragment extends WindowContainer<WindowContainer> { // area, i.e. the screen area without the system bars. // The non decor inset are areas that could never be removed in Honeycomb. See // {@link WindowManagerPolicy#getNonDecorInsetsLw}. calculateInsetFrames(mTmpNonDecorBounds, mTmpStableBounds, mTmpFullBounds, di, false /* useLegacyInsetsForStableBounds */); calculateInsetFrames(mTmpNonDecorBounds, mTmpStableBounds, mTmpFullBounds, di); } else { // Apply the given non-decor and stable insets to calculate the corresponding bounds // for screen size of configuration. Loading Loading @@ -2430,11 +2429,9 @@ class TaskFragment extends WindowContainer<WindowContainer> { * @param outNonDecorBounds where to place bounds with non-decor insets applied. * @param outStableBounds where to place bounds with stable insets applied. * @param bounds the bounds to inset. * @param useLegacyInsetsForStableBounds {@code true} if we need to use the legacy insets frame * for apps targeting U or before when calculating stable bounds. */ void calculateInsetFrames(Rect outNonDecorBounds, Rect outStableBounds, Rect bounds, DisplayInfo displayInfo, boolean useLegacyInsetsForStableBounds) { DisplayInfo displayInfo) { outNonDecorBounds.set(bounds); outStableBounds.set(bounds); if (mDisplayContent == null) { Loading @@ -2446,11 +2443,7 @@ class TaskFragment extends WindowContainer<WindowContainer> { final DisplayPolicy.DecorInsets.Info info = policy.getDecorInsetsInfo( displayInfo.rotation, displayInfo.logicalWidth, displayInfo.logicalHeight); intersectWithInsetsIfFits(outNonDecorBounds, mTmpBounds, info.mNonDecorInsets); if (!useLegacyInsetsForStableBounds) { intersectWithInsetsIfFits(outStableBounds, mTmpBounds, info.mConfigInsets); } else { intersectWithInsetsIfFits(outStableBounds, mTmpBounds, info.mOverrideConfigInsets); } } /** Loading