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

Commit 23f2d712 authored by Ben Lin's avatar Ben Lin Committed by Android (Google) Code Review
Browse files

Merge "Update WMWrapper when we get a new relayout call." into main

parents aad9e30a c56cddb6
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -524,6 +524,13 @@ public class DesktopModeWindowDecoration extends WindowDecoration<WindowDecorLin
            setCapturedLink(taskInfo.capturedLink, taskInfo.capturedLinkTimestamp);
        }

        if (DesktopExperienceFlags.ENABLE_BUG_FIXES_FOR_SECONDARY_DISPLAY.isTrue()) {
            final Context dc = mDisplayController.getDisplayContext(taskInfo.displayId);
            if (dc != null) {
                mWindowManagerWrapper.updateWindowManager(dc.getSystemService(WindowManager.class));
            }
        }

        if (isHandleMenuActive()) {
            mHandleMenu.relayout(
                    startT,
+5 −2
Original line number Diff line number Diff line
@@ -24,9 +24,8 @@ import android.view.WindowManager
 * decors more testable.
 */
class WindowManagerWrapper (
    private val windowManager: WindowManager
    private var windowManager: WindowManager
){

    fun addView(v: View, lp: WindowManager.LayoutParams) {
        windowManager.addView(v, lp)
    }
@@ -38,4 +37,8 @@ class WindowManagerWrapper (
    fun updateViewLayout(v: View, lp: WindowManager.LayoutParams) {
        windowManager.updateViewLayout(v, lp)
    }

    fun updateWindowManager(windowManager: WindowManager) {
        this.windowManager = windowManager
    }
}
 No newline at end of file