Cleanup of AccessibilityUtil#hasValueInSettings
Settings should now be able to directly use the equivalent ShortcutUtils functions, so the unnecessary code is being removed from AccessibilityUtil. This does cause much behavior to depend on A11yManager instead of Settings.Secure, so several tests need their conditions updated. Test: atest com.android.settings.accessibility Flag: EXEMPT internal refactoring Bug: 367414968 Change-Id: I95f81f7d78b074def0fe2d1e01f60ceb7e142dac
This commit is contained in:
@@ -16,6 +16,8 @@
|
||||
|
||||
package com.android.settings.accessibility;
|
||||
|
||||
import static com.android.internal.accessibility.common.ShortcutConstants.UserShortcutType.SOFTWARE;
|
||||
|
||||
import static com.google.common.truth.Truth.assertThat;
|
||||
|
||||
import static org.mockito.ArgumentMatchers.any;
|
||||
@@ -564,9 +566,8 @@ public class AccessibilitySettingsTest {
|
||||
}
|
||||
|
||||
private void setShortcutEnabled(ComponentName componentName, boolean enabled) {
|
||||
Settings.Secure.putString(mContext.getContentResolver(),
|
||||
Settings.Secure.ACCESSIBILITY_BUTTON_TARGETS,
|
||||
enabled ? componentName.flattenToString() : "");
|
||||
mShadowAccessibilityManager.setAccessibilityShortcutTargets(
|
||||
SOFTWARE, (enabled) ? List.of(componentName.flattenToString()) : List.of());
|
||||
}
|
||||
|
||||
private BooleanSubject assertUriObserversContainsClazz(
|
||||
|
Reference in New Issue
Block a user