[Mag] Keyboard shortcut info shown when physical keyboard present

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
This commit is contained in:
Katie Dektar
2025-02-14 19:26:12 +00:00
parent e0dc58fc79
commit e94d88c74e
4 changed files with 129 additions and 18 deletions

View File

@@ -5330,6 +5330,16 @@
{4,number,integer}. Lift finger to stop magnification
]]>
</string>
<!-- Instructions on the accessibility preference screen teaching the user how to control magnification with a keyboard. [CHAR LIMIT=none] -->
<string name="accessibility_screen_magnification_keyboard_summary">
<![CDATA[
<b>To zoom with the keyboard:</b><br/>
{0,number,integer}. Use the shortcut to start magnification<br/>
{1,number,integer}. Hold down <xliff:g id="meta1">%1$s</xliff:g> and <xliff:g id="alt1">%2$s</xliff:g> and press + or - to zoom in or out<br/>
{2,number,integer}. Hold down <xliff:g id="meta2">%3$s</xliff:g> and <xliff:g id="alt2">%4$s</xliff:g> and press the arrow keys to move around the screen<br/>
{3,number,integer}. Use the shortcut to stop magnification
]]>
</string>
<!-- Instructions on the accessibility preference screen teaching the user how to interact with screen magnification when one finger panning feature is turned off. [CHAR LIMIT=none] -->
<string name="accessibility_screen_magnification_summary_one_finger_panning_off">
<![CDATA[