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

Commit 9eb68bb7 authored by Anushree Ganjam's avatar Anushree Ganjam
Browse files

Developer options should reflect the correct DeviceConfig value for ReleaseFlag.

Before this change : When a ReleaseFlag is turned on from server side or
set in DeviceConfig, developer options shows the flag is off.

After this change : When a ReleaseFlag is turned on from server side or
set in DeviceConfig, developer options shows the flag is on.

This change doesn't reflect the DeviceConfig value changes done using
`adb shell device_config put` unless launcher is restarted.

Bug: 297202824
Test: Manual
Flag: NA

Change-Id: I5d83207cf454c60278fd02e59199207e855d51a8
parent a9928fae
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -116,8 +116,9 @@ public class FlagsFactory {
        boolean defaultValue = DeviceConfig.getBoolean(NAMESPACE_LAUNCHER, key, defaultValueInCode);
        if (IS_DEBUG_DEVICE) {
            boolean currentValue = getSharedPreferences().getBoolean(key, defaultValue);
            DebugFlag flag = new DeviceFlag(key, description, flagState, currentValue,
                    defaultValueInCode);
            DebugFlag flag = new DeviceFlag(key, description,
                    (defaultValue == defaultValueInCode) ? flagState
                            : defaultValue ? ENABLED : DISABLED, currentValue, defaultValueInCode);
            sDebugFlags.add(flag);
            return flag;
        } else {