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

Commit bee1fb93 authored by Dianne Hackborn's avatar Dianne Hackborn
Browse files

DO NOT MERGE. Fix issue #8868003: Recents thumbnails scale...

...+ zoom to wrong place

We need to make sure the overscan insets are never negative.

Change-Id: I6ca82acc2a6c887085a5d14d03a55ea78451e4b6
parent 214cb0d4
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -534,10 +534,10 @@ final class WindowState implements WindowManagerPolicy.WindowState {
        if (visible.bottom > frame.bottom) visible.bottom = frame.bottom;

        final Rect overscanInsets = mOverscanInsets;
        overscanInsets.left = overscan.left-frame.left;
        overscanInsets.top = overscan.top-frame.top;
        overscanInsets.right = frame.right-overscan.right;
        overscanInsets.bottom = frame.bottom-overscan.bottom;
        overscanInsets.left = overscan.left > frame.left ? overscan.left-frame.left : 0;
        overscanInsets.top = overscan.top > frame.top ? overscan.top-frame.top : 0;
        overscanInsets.right = overscan.right < frame.right ? frame.right-overscan.right : 0;
        overscanInsets.bottom = overscan.bottom < frame.bottom ? frame.bottom-overscan.bottom : 0;

        final Rect contentInsets = mContentInsets;
        contentInsets.left = content.left-frame.left;