Refactor SettingsContentObserver and add it to follow typing feature.
Refactor SettingsContentObserver and rename it to AccessibilitySettingsContentObserver. Besides, we register it to observe follow typing feature preference value. The reasons behind refactor: 1. We change callback signature due to the consistency for register it by preference key, not by Uri. 2. We refactor the default preference key to a seperate method. Since the default value is related to accessibility, we rename it with accessibility prefix. 3. We can register different callback for difference collections of preference keys. Default preference keys: They existed in the previous constructor. 1. Settings.Secure.ACCESSIBILITY_ENABLED 2. Settings.Secure.ENABLED_ACCESSIBILITY_SERVICES Bug: 194668976 Test: make RunSettingsRoboTests ROBOTEST_FILTER= AccessibilitySettingsTest AccessibilitySettingsContentObserverTest AccessibilityShortcutPreferenceFragmentTest MagnificationFollowTypingPreferenceControllerTest ToggleFeaturePreferenceFragmentTest ToggleScreenMagnificationPreferenceFragmentTest Change-Id: Iafd27e044ebe2536ae7ae55c1c80af54f7f0f822
Loading
Please register or sign in to comment