This makes sure the cursor following mode setting to be visible only
when a mouse device is detected.
Bug: b/398066000
Flag: com.android.settings.accessibility.enable_magnification_cursor_following_dialog
Test: com.android.settings.accessibility.ToggleScreenMagnificationPreferenceFragmentTest
Change-Id: I7dd27e9d8a841461900e28d8ae07d17f86a0b662
This a pure UI change that adds a new magnification cursor following
mode dialog behind a flag. The framework support will be added
separately later.
There are 3 modes as the following:
- continuous mode
- center mode
- edge mode
It also renames magnification mode dialog xml file for general purpose
within accessibility.
NO_IFTTT=linter not working
Bug: b/388335935
Flag: com.android.settings.accessibility.enable_magnification_cursor_following_dialog
Test: SettingsRoboTests:com.android.settings.accessibility.ToggleScreenMagnificationPreferenceFragmentTest &&
SettingsRoboTests:com.android.settings.accessibility.MagnificationModePreferenceControllerTest &&
SettingsRoboTests:com.android.settings.accessibility.MagnificationCursorFollowingModePreferenceControllerTest
Change-Id: If2672186faf7443cc210d79630b1ea4f3808d7e4
Shows keyboard shortcut info in magnification settings when a
physical keyboard is present. See bug for screenshots.
Hides touchscreen info in magnification settings when a touchscreen
is not present.
Adds ShadowInputDevice support for physical full keyboards.
Bug: b/388847050
Test: Manual, atest ToggleScreenMagnificationPreferenceFragmentTest
Flag: com.android.server.accessibility.enable_magnification_keyboard_control
Change-Id: Ib53fbd8f929d1cc8e294f6f04bab405c9bb576a9
Fix: 378876803
Flag: EXEMPT custom flagging helpers from Settings and Setup
Test: observe new image; see bug screenshots
Change-Id: I3654563352e223af1a0d679318da45da2b4bc8be
This cleans up the magnification mode controller and related code. It
also fixes most of the lint errors in the files.
NO_IFTTT=linter not working
Bug: b/388335935
Flag: EXEMPT refactor
Test: com.android.settings.accessibility.ToggleScreenMagnificationPreferenceFragmentTest & com.android.settings.accessibility.MagnificationModePreferenceControllerTest
Change-Id: I368128c3c71285a9511a7831e1d01232e7536d2f
Bug: 367414968
Test: atest com.android.settings.accessibility
Flag: EXEMPT cleanup
NO_IFTTT= Change does not alter preference list
Change-Id: I64f5f7fba112b6fb5035b88f01c04d9ee309f2c0
This entry point allows users to access and adjust Magnification
settings for low vision accessibility. Visibility is controlled by
the aconfig flag and SurveyFeatureProvider#isSurveyAvailable.
NO_IFTTT=Revisit preference_list scope
Bug: 380346799
Test: atest ToggleScreenMagnificationPreferenceFragmentTest
Flag: com.android.server.accessibility.enable_low_vision_hats
Change-Id: I81a55487734fe7b139391a6c95834c7313e54d7a
Also renames mPackageName to mFeatureName. This string is used as the
user-visible feature name, e.g. TalkBack, not the APK package name.
Fix: 382054546
Test: n/a (existing presubmit)
Flag: EXEMPT minor bugfix
Change-Id: I1ce6902612d89bbb68bddf30227ca231ea98dce7
Removes all instances of a11y_qs_enabled. Any code that would be nontrivial to remove has been deprecated for later cleanup.
Test: atest com.android.settings.accessibility
Flag: EXEMPT flag cleanup
Bug: 367414968
Change-Id: I81f3c9cee377535eaa552a170d58ec1a79d1da65
All preferences are searchable except for "Keep on while switching apps"
which is only searchable if the user already has a magnification
shortcut enabled, to minimize user confusion from that generically-named
preference.
NO_IFTTT=adding IFTTT
Fix: 353772926
Test: atest ToggleScreenMagnificationPreferenceFragmentTest
Flag: com.android.settings.accessibility.fix_a11y_settings_search
Test: adb shell pm clear com.google.android.settings.intelligence;
search Settings for the items in the bug
Change-Id: I01c7e5586ec0ea432cb2df80f156141683b97522
Properly integrating GESTURE into Settings, so that text pertaining to the gesture shortcut are displayed when appropriate.
Heavy refactoring has been done to allow for easier cleanup and expansion
Demo video: https://x20web.corp.google.com/users/jo/jonesriley/splitShortcut/a11ySettingsGestureCompat.mp4
NO_IFTTT=changes do not alter the order of the shortcuts.
Bug: 365570709
Test: atest com.android.settings.accessibility
Flag: android.provider.a11y_standalone_gesture_enabled
Change-Id: If90719763a48e3b8bc35988a1de9a352a766953b
- Cleaned up the code that won't be executed when the flag is on
- Remove unused resources
Bug: 300302098
Test: Manually verify the user can change the shortcut type, and the
changes are saved
Test: atest com.android.settings.accessibility
Flag: EXEMPT removing com.android.settings.accessibility.edit_shortcuts_in_full_screen
Change-Id: I1e32b724ca3da909feda55e20fb1d51dc4680c09
This removes AccessibilityUtil.UserShortcutType,
replacing all mention of it with ShortcutConstants.UserShortcutType
NO_IFTTT=UI order not changed
Test: atest com.android.settings.accessibility
Bug: 322014084
Flag: EXEMPT internal refactoring
Change-Id: I18695d040c4bd08a455143594e770adda2b1a8de
Based on b/338409557#comment5, we update the onefingerpan toggle's
summary, and make the magnification settings page's footer HTML
description be dynamic based on one finger panning preference state.
Bug: 338409557
Flag: com.android.server.accessibility.enable_magnification_one_finger_panning_gesture
Test: manually
atest MagnificationOneFingerPanningPreferenceControllerTest
atest ToggleScreenMagnificationPreferenceFragmentTest
atest ToggleFeaturePreferenceFragmentTest
Change-Id: I817cad4fb0c034bcd2db0485ca27c30ea88a0280
AccessibilityShortcutsTutorial.
**Root cause**
When toggle the shortcut, it asks the AccessibilityManager to turn on
the shortcut and update the Settings data. Internally, the
AccessibilityManager delegate the work to AccessibilityManagerService
via a oneway binder call.
In the past, when launching the AccessibilityShortcutsTutorial, we
assume the shortcut selection are saved in the Settings before launching
the AccessibilityShortcutsTutorial. So we pass whatever are in the
Settings as what the user has selected to the tutorial.
This is not true anymore since we use the oneway AIDL call to do the
updates. The data in Settings may not yet be updated before we use it to
launch the tutorial.
Since the user preferred shortcuts are always set before we attempt to
launch the AccessibilityShortcutsTutorial, we can rely on it instead of
the Settings value to launch the AccessibilityShortcutsTutorial for the
selected shortcut options.
**Changes in this cl**
- Mechanical refactor to extract the lines to get the user preferred
shortcut into a method.
- Use the new method to grab the shortcut options to pass to the
AccessibilityShortcutsTutorial to prevent the crash.
Bug: 341176890
Test: manual
- Modify the AccessibilityManagerService locally to delay processing
the request to update the shortcut options in Settings data
- Turn on the shortcut toggle, and verify the app won't crash
Test: atest com.android.settings.accessibility
Flag: EXEMPT bugfix (low risk + mechanical refactor)
Change-Id: Id3cc4cc5f6667061545955881632544472aedd95
Although we haven't implemented joystick feature, but the joystick
preference controller is already in the codebase, so we also add hiding
logic for joystick toggle when in setup wizard.
Bug: 340721852
Flag: NONE
Test: manually
atest MagnificationJoystickPreferenceControllerTest
Change-Id: Ife93548583c3e82eac030e6e3aa55b9f643b055a
Originally we cache mFollowingTypingSwitchPreference in fragment so in
ToggleScreenMagnificationPreferenceFragmentForSetupWizard we can set the
preference visible to false to hide it. After creating MagnificationFeaturePreferenceController,
the MagnificationFollowTypingPreferenceController can extend it and
check isInSetupWizard internally then dicide whether to hide. Therefore,
we don't need to cache mFollowingTypingSwitchPreference in fragment
and let the fragment control the preference visibility anymore.
Bug: 340721852
Flag: NONE
Test: manually
atest MagnificationFollowTypingPreferenceControllerTest
atest ToggleScreenMagnificationPreferenceFragmentForSetupWizardTest
atest ToggleScreenMagnificationPreferenceFragmentTest
Change-Id: I44f7f0589b2df3d83a27139323fc68a0561f1cfa
Add a new abstract class MagnificationFeaturePreferenceController
that extends TogglePreferenceController, to wrap inSetupWizard
setter/getter. Then for magnification feature preference controllers
like alwaysOn or followTyping, they can just check isInSetupWizard to
decide whether hiding in setup wizard.
Besides, in ToggleScreenMagnificationPreferenceFragment we cache a flag
mInSetupWizard when fragment created, so we can pass the info to the
preferece controllers when creating them.
Bug: 340721852
Flag: NONE
Test: build pass
Change-Id: I05c59a766219862117d2a6ede775d68a4c3dedac
In ag/26349366 we wrapped the follow typing prefernce creation into new
method, but in the new method we didn't assign the created preference to
mFollowingTypingSwitchPreference. So
ToggleScreenMagnificationPreferenceFragmentForSetupWizard can not access
the preference object to hide it. Therefore, as a short-term solution we
assign the created preference to mFollowingTypingSwitchPreference. For a
long-term plan we should not create a preference and hide it in suw,
instead we don't need to create that preference. (tracked in b/335788167)
Bug: 335788769
Flag: NONE
Test: manually
Change-Id: Ideef93127343b7d1105a63006d343cd5ef66de08
Like MagnificationAlwaysOn toggle behavior, when the magnification
capability is window-mode only we'll hide the OneFingerPan toggle too.
Also do a small refactoring in MagnificationOneFingerPanningPreferenceControllerTest
Bug: 333821725
Flag: ACONFIG com.android.server.accessibility.enable_magnification_one_finger_panning_gesture TEAMFOOD
Test: manually
atest MagnificationOneFingerPanningPreferenceControllerTest
atest ToggleScreenMagnificationPreferenceFragmentTest
Change-Id: I8684b5bae5cbfc5b75fc4c14d2e9173b17d0fb02
As b/328787031, we make the MagnificationAlwaysOnPreferenceController observe the magnification capabilities then update the preference enabled state. Therefore, when changing the capabilities to window mode only, the preference will become unavailable.
We use the bug-fix flag to verify the fix with rollout process.
Bug: 328787031
Flag: ACONFIG com.android.settings.accessibility.hide_magnification_always_on_toggle_when_window_mode_only DEVELOPMENT
Test: manually flip the flag
atest MagnificationCapabilitiesTest
atest ToggleScreenMagnificationPreferenceFragmentTest
atest MagnificationAlwaysOnPreferenceControllerTest
Change-Id: I1a25f80131d84ecdd927030e40a18ebb32b7862f
AccessibilityGestureNavigationTutorial is not only for displaying
tutorial for accessibility gesture shortcut. It's used for display the
tutorials for all the selected accessibility shortcuts. Renamed the
class to match it's responsibility.
Bug: N/A
Flag: EXEMPT Strict mechanical refactors
Test: build succeed locally
Change-Id: I1dd212abc660454e77f18f770c2ecc17be320eaa
As b/186731461, so far MagnificationModePreferenceController and other
magnification preference controllers are only used in
ToggleScreenMagnificationPreferenceFragment, which is DashboardFragment.
Since DashboardFragment already updates preference state in its
onResume, so we can remove the onResume overrides in those controllers.
Besides, we can also remove the LifeCycle dependency for the controllers
since it's not used anymore.
Bug: 186731461
Flag: NA
Test: manually
atest ToggleScreenMagnificationPreferenceFragmentTest
atest MagnificationAlwaysOnPreferenceControllerTest
atest MagnificationFollowTypingPreferenceControllerTest
atest MagnificationJoystickPreferenceControllerTest
atest MagnificationModePreferenceControllerTest
Change-Id: I379a6a3a985c9d8b7a37bbb878b84cee1bd6adfb
This helps differentiate this from other magnification tools.
Reuses (and slightly modifies) the `magnification_feature_summary`
string which was not used by any existing code. This helps ensure
the existing localizations should be close enough, until L10n
translators have time to update based on the new shorter version.
Bug: 303499185
Test: ToggleScreenMagnificationPreferenceFragmentTest
Test: Open Settings > Accessibility, observe summary
Change-Id: If5ee4f937bbd655b425d4767ad8bbcef08dbe345
The shortcut is separate from single-finger triple-tap. It’s under hardware shortcut and above/outside of Advanced section.
Bug: 297805269
Test: manual
Test: atest ToggleScreenMagnificationPreferenceFragmentTest
Change-Id: Id74cf3e457c04e167f3100d977b6c70c5d601026
- Keep the accessibility settings strings the same as in U.
Bug: 289425138
Test: manual
Test: atest
Change-Id: Iddbbfe627c93529d2421e153094a30628229c4bc
Set the settings shortcut size to large when the Magnification shortcut it enabled. Provide users with the large size as the default, which is easy to see.
Bug: 283844702
Test: manually - attach videos in the bug
Test: atest ToggleScreenMagnificationPreferenceFragmentTest
Test: make RunSettingsRoboTests ROBOTEST_FILTER=ToggleScreenMagnificationPreferenceFragmentTest
Change-Id: I8fac5780b8388b1b4f124cffbdd305235f035e72
Set the feature flag getter default return value to be true to rollout to public. We keep the checking code so that it's still remote controllable.
Bug: 281788002
Test: manually test with adb command
Change-Id: Ie7f32721cf99d8a97c11f0f9c6d0d466c083d668
Revert submission 19748582-settings_yesno
Reason for revert: Common strings in English could be translated into different strings in other languages.
Reverted changes: /q/submissionid:19748582-settings_yesno
Bug: 272603842
Test: build and open Settings app
Test: atest SettingsRoboTests
Change-Id: Iaad301c5513478fb95e40987ea3ccb4f923d71fa
Before this CL, Magnification Settings can only be
launched from MagnificationPreferenceController.
This CL initializes FooterPreferenceController if the
parent class does not initialize it from Intent extras.
Bug: 268411305
Test: manual
make RunSettingsRoboTests ROBOTEST_FILTER=MagnificationGesturesPreferenceControllerTest
make RunSettingsRoboTests ROBOTEST_FILTER=ToggleScreenMagnificationPreferenceFragmentTest
Change-Id: I954739c39c823ce7fe0daa711743f729d182571b