Remove mentions of "gesture" on the Accessibility Button settings page
Configures page to hide/replace elements that would mention gesture. Also, provides context when necessary if a setting is disabled by the current button mode. Demonstration video: https://x20web.corp.google.com/users/jo/jonesriley/splitShortcut/a11yShortcutSettingsCleanup.mp4 Test: manual, navigate to the Accessibility Button "more options" page in gesture navigation mode. Verify there are no references to gesture. Bug: 349178639 Flag: android.provider.a11y_standalone_gesture_enabled Change-Id: I067738d23e74c00bab4010d187820d09013809ad
This commit is contained in:
@@ -33,8 +33,15 @@ public class AccessibilityButtonFragment extends DashboardFragment {
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
final int titleResource = AccessibilityUtil.isGestureNavigateEnabled(getPrefContext())
|
||||
? R.string.accessibility_button_gesture_title : R.string.accessibility_button_title;
|
||||
|
||||
final int titleResource;
|
||||
if (android.provider.Flags.a11yStandaloneGestureEnabled()) {
|
||||
titleResource = R.string.accessibility_button_title;
|
||||
} else {
|
||||
titleResource = AccessibilityUtil.isGestureNavigateEnabled(getPrefContext())
|
||||
? R.string.accessibility_button_gesture_title
|
||||
: R.string.accessibility_button_title;
|
||||
}
|
||||
getActivity().setTitle(titleResource);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user