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

Commit cd544e65 authored by Fiona Campbell's avatar Fiona Campbell Committed by Android (Google) Code Review
Browse files

Merge "Make display manager logging conditional" into main

parents 308f7866 6f6010a6
Loading
Loading
Loading
Loading
+2 −4
Original line number Diff line number Diff line
@@ -1435,12 +1435,10 @@ public final class DisplayManagerGlobal {
            sExtraDisplayListenerLogging = !TextUtils.isEmpty(EXTRA_LOGGING_PACKAGE_NAME)
                    && EXTRA_LOGGING_PACKAGE_NAME.equals(sCurrentPackageName);
        }
        // TODO: b/306170135 - return sExtraDisplayListenerLogging instead
        return true;
        return sExtraDisplayListenerLogging;
    }

    private static boolean extraLogging() {
        // TODO: b/306170135 - return sExtraDisplayListenerLogging & package name check instead
        return true;
        return sExtraDisplayListenerLogging;
    }
}
+1 −2
Original line number Diff line number Diff line
@@ -1020,8 +1020,7 @@ public final class ViewRootImpl implements ViewParent,
        mDisplay = display;
        mBasePackageName = context.getBasePackageName();
        final String name = DisplayProperties.debug_vri_package().orElse(null);
        // TODO: b/306170135 - return to using textutils check on package name.
        mExtraDisplayListenerLogging = true;
        mExtraDisplayListenerLogging = !TextUtils.isEmpty(name) && name.equals(mBasePackageName);
        mThread = Thread.currentThread();
        mLocation = new WindowLeaked(null);
        mLocation.fillInStackTrace();
+2 −4
Original line number Diff line number Diff line
@@ -590,8 +590,7 @@ public final class DisplayManagerService extends SystemService {
        mSystemReady = false;
        mConfigParameterProvider = new DeviceConfigParameterProvider(DeviceConfigInterface.REAL);
        mExtraDisplayLoggingPackageName = DisplayProperties.debug_vri_package().orElse(null);
        // TODO: b/306170135 - return TextUtils package name check instead
        mExtraDisplayEventLogging = true;
        mExtraDisplayEventLogging = !TextUtils.isEmpty(mExtraDisplayLoggingPackageName);
    }

    public void setupSchedulerPolicies() {
@@ -3048,8 +3047,7 @@ public final class DisplayManagerService extends SystemService {
    }

    private boolean extraLogging(String packageName) {
        // TODO: b/306170135 - return mExtraDisplayLoggingPackageName & package name check instead
        return true;
        return mExtraDisplayEventLogging && mExtraDisplayLoggingPackageName.equals(packageName);
    }

    // Runs on Handler thread.