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

Commit 30b5abe5 authored by Adithya Srinivasan's avatar Adithya Srinivasan
Browse files

Remove owerUid from WindowSurfaceController constructor

The ownerUid is already available inside WindowSession and we obtain the
ownerPid from it. To make things consitent, this change removes the
redundant parameter passed to WindowSurfaceController.

Bug: 170911969
Test: System bootup
Change-Id: I2f707d195e72f3ee7b8996de00d0d026c6a2dd1b
parent 2bc43dca
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2506,7 +2506,7 @@ public class WindowManagerService extends IWindowManager.Stub
        WindowSurfaceController surfaceController;
        try {
            Trace.traceBegin(TRACE_TAG_WINDOW_MANAGER, "createSurfaceControl");
            surfaceController = winAnimator.createSurfaceLocked(win.mAttrs.type, win.mOwnerUid);
            surfaceController = winAnimator.createSurfaceLocked(win.mAttrs.type);
        } finally {
            Trace.traceEnd(TRACE_TAG_WINDOW_MANAGER);
        }
+2 −2
Original line number Diff line number Diff line
@@ -420,7 +420,7 @@ class WindowStateAnimator {
        }
    }

    WindowSurfaceController createSurfaceLocked(int windowType, int ownerUid) {
    WindowSurfaceController createSurfaceLocked(int windowType) {
        final WindowState w = mWin;

        if (mSurfaceController != null) {
@@ -480,7 +480,7 @@ class WindowStateAnimator {
            }

            mSurfaceController = new WindowSurfaceController(attrs.getTitle().toString(), width,
                    height, format, flags, this, windowType, ownerUid);
                    height, format, flags, this, windowType);
            mSurfaceController.setColorSpaceAgnostic((attrs.privateFlags
                    & WindowManager.LayoutParams.PRIVATE_FLAG_COLOR_SPACE_AGNOSTIC) != 0);

+2 −2
Original line number Diff line number Diff line
@@ -80,7 +80,7 @@ class WindowSurfaceController {
    boolean mChildrenDetached;

    WindowSurfaceController(String name, int w, int h, int format,
            int flags, WindowStateAnimator animator, int windowType, int ownerUid) {
            int flags, WindowStateAnimator animator, int windowType) {
        mAnimator = animator;

        mSurfaceW = w;
@@ -102,7 +102,7 @@ class WindowSurfaceController {
                .setFormat(format)
                .setFlags(flags)
                .setMetadata(METADATA_WINDOW_TYPE, windowType)
                .setMetadata(METADATA_OWNER_UID, ownerUid)
                .setMetadata(METADATA_OWNER_UID, mWindowSession.mUid)
                .setMetadata(METADATA_OWNER_PID, mWindowSession.mPid)
                .setCallsite("WindowSurfaceController");