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

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

Merge "Reset compat mode settings on settings change."

parents 97c5a858 3e813b42
Loading
Loading
Loading
Loading
+13 −0
Original line number Diff line number Diff line
@@ -524,6 +524,7 @@ public final class AutofillManagerService extends SystemService {

    private void addCompatibilityModeRequestsLocked(@NonNull AutofillManagerServiceImpl service
            , int userId) {
        mAutofillCompatState.reset();
        final ArrayMap<String, Pair<Long, String>> compatPackages =
                service.getCompatibilityPackagesLocked();
        if (compatPackages == null || compatPackages.isEmpty()) {
@@ -626,6 +627,15 @@ public final class AutofillManagerService extends SystemService {
                }
            }
        }

        void reset() {
            synchronized (mLock) {
                if (mUserSpecs != null) {
                    mUserSpecs.clear();
                    mUserSpecs = null;
                }
            }
        }
    }

    final class AutoFillManagerServiceStub extends IAutoFillManager.Stub {
@@ -1045,6 +1055,9 @@ public final class AutofillManagerService extends SystemService {
                    Settings.Secure.AUTOFILL_SERVICE), false, this, UserHandle.USER_ALL);
            resolver.registerContentObserver(Settings.Secure.getUriFor(
                    Settings.Secure.USER_SETUP_COMPLETE), false, this, UserHandle.USER_ALL);
            resolver.registerContentObserver(Settings.Global.getUriFor(
                    Settings.Global.AUTOFILL_COMPAT_ALLOWED_PACKAGES), false, this,
                    UserHandle.USER_ALL);
        }

        @Override