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

Commit a9d4a6d2 authored by Ricardo Cerqueira's avatar Ricardo Cerqueira Committed by Gerrit Code Review
Browse files

Merge "Keydisabler: fix button light restore logic" into cm-11.0

parents 7b153376 25b21eb3
Loading
Loading
Loading
Loading
+6 −4
Original line number Diff line number Diff line
@@ -450,11 +450,13 @@ public class ButtonSettings extends SettingsPreferenceFragment implements
            Settings.System.putInt(context.getContentResolver(),
                    Settings.System.BUTTON_BRIGHTNESS, 0);
        } else {
            int oldBright = prefs.getInt("pre_navbar_button_backlight", -1);
            if (oldBright != -1) {
                Settings.System.putInt(context.getContentResolver(),
                    Settings.System.BUTTON_BRIGHTNESS,
                    prefs.getInt("pre_navbar_button_backlight", defaultBrightness));
                        Settings.System.BUTTON_BRIGHTNESS, oldBright);
                editor.remove("pre_navbar_button_backlight");
            }
        }
        editor.commit();
    }