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

Commit 085797df authored by Roy Chou's avatar Roy Chou Committed by Gerrit Code Review
Browse files

Merge "fix(#Magnification): mis-use non resoure id in resource getter when...

Merge "fix(#Magnification): mis-use non resoure id in resource getter when magnification capability setup"
parents c25c1ca1 b7547b46
Loading
Loading
Loading
Loading
+5 −4
Original line number Diff line number Diff line
@@ -5001,14 +5001,15 @@ public class SettingsProvider extends ContentProvider {
                            Secure.ACCESSIBILITY_MAGNIFICATION_CAPABILITY);
                    final boolean supportMagnificationArea = getContext().getResources().getBoolean(
                            com.android.internal.R.bool.config_magnification_area);
                    final int capability = supportMagnificationArea
                            ? R.integer.def_accessibility_magnification_capabilities
                            : Secure.ACCESSIBILITY_MAGNIFICATION_MODE_FULLSCREEN;
                    final String supportShowPrompt = supportMagnificationArea ? "1" : "0";
                    if (magnificationCapabilities.isNull()) {
                        final int capability = supportMagnificationArea
                                ? getContext().getResources().getInteger(
                                        R.integer.def_accessibility_magnification_capabilities)
                                : Secure.ACCESSIBILITY_MAGNIFICATION_MODE_FULLSCREEN;
                        secureSettings.insertSettingLocked(
                                Secure.ACCESSIBILITY_MAGNIFICATION_CAPABILITY,
                                String.valueOf(getContext().getResources().getInteger(capability)),
                                String.valueOf(capability),
                                null, true, SettingsState.SYSTEM_PACKAGE_NAME);

                        if (isMagnificationSettingsOn(secureSettings)) {