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

Commit 349b5873 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Automatically load ActivityManager DeviceConfig constants."

parents 9f982f56 c85bbe00
Loading
Loading
Loading
Loading
+7 −6
Original line number Diff line number Diff line
@@ -438,14 +438,15 @@ final class ActivityManagerConstants extends ContentObserver {
        DeviceConfig.addOnPropertiesChangedListener(DeviceConfig.NAMESPACE_ACTIVITY_MANAGER,
                ActivityThread.currentApplication().getMainExecutor(),
                mOnDeviceConfigChangedListener);
        updateMaxCachedProcesses();
        loadDeviceConfigConstants();
        // The following read from Settings.
        updateActivityStartsLoggingEnabled();
        updateBackgroundActivityStarts();
        updateForceRestrictedBackgroundCheck();
        updateForegroundServiceStartsLoggingEnabled();
        updateBackgroundFgsStartsRestriction();
        updateOomAdjUpdatePolicy();
        updateImperceptibleKillExemptions();
    }

    private void loadDeviceConfigConstants() {
        mOnDeviceConfigChangedListener.onPropertiesChanged(
                DeviceConfig.getProperties(DeviceConfig.NAMESPACE_ACTIVITY_MANAGER));
    }

    public void setOverrideMaxCachedProcesses(int value) {