Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2d8d2456 authored by Tiger Huang's avatar Tiger Huang Committed by Automerger Merge Worker
Browse files

Merge "Don't send mSizeCompatScale to client if it is from SizeCompatBounds"...

Merge "Don't send mSizeCompatScale to client if it is from SizeCompatBounds" into tm-qpr-dev am: d76c6279

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20419089



Change-Id: If243c31b640a63b8fa92f1f17115994adc9eb5c7
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 98801e7c d76c6279
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1883,7 +1883,7 @@ public class WindowManagerService extends IWindowManager.Stub
                // Make this invalid which indicates a null attached frame.
                outAttachedFrame.set(0, 0, -1, -1);
            }
            outSizeCompatScale[0] = win.getSizeCompatScale();
            outSizeCompatScale[0] = win.getSizeCompatScaleForClient();
        }

        Binder.restoreCallingIdentity(origId);
+6 −3
Original line number Diff line number Diff line
@@ -1265,8 +1265,10 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP
        mGlobalScale = mInvGlobalScale = mSizeCompatScale = 1f;
    }

    float getSizeCompatScale() {
        return mSizeCompatScale;
    float getSizeCompatScaleForClient() {
        // If the size compat scale is because of the size compat bounds, we only scale down its
        // coordinates at the server side without letting the client know.
        return mToken.hasSizeCompatBounds() ? 1f : mSizeCompatScale;
    }

    /**
@@ -3863,7 +3865,8 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP
                outFrames.attachedFrame.scale(mInvGlobalScale);
            }
        }
        outFrames.sizeCompatScale = mSizeCompatScale;

        outFrames.sizeCompatScale = getSizeCompatScaleForClient();

        // Note: in the cases where the window is tied to an activity, we should not send a
        // configuration update when the window has requested to be hidden. Doing so can lead to