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

Commit bda5ee8c authored by Ady Abraham's avatar Ady Abraham
Browse files

mMaximumObscuringOpacityForTouch should remain valid

set mMaximumObscuringOpacityForTouch to the defaul value in case
that the system settings contains an invalid value.

Change-Id: I4f15a7573913b503635995d26053bed9aa753a45
Test: presubmit
Bug: 238983569
parent 06d1cb69
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -899,6 +899,11 @@ public class WindowManagerService extends IWindowManager.Stub
            mMaximumObscuringOpacityForTouch = Settings.Global.getFloat(resolver,
                    Settings.Global.MAXIMUM_OBSCURING_OPACITY_FOR_TOUCH,
                    InputManager.DEFAULT_MAXIMUM_OBSCURING_OPACITY_FOR_TOUCH);
            if (mMaximumObscuringOpacityForTouch < 0.0f
                    || mMaximumObscuringOpacityForTouch > 1.0f) {
                mMaximumObscuringOpacityForTouch =
                        InputManager.DEFAULT_MAXIMUM_OBSCURING_OPACITY_FOR_TOUCH;
            }
        }

        void updateSystemUiSettings(boolean handleChange) {