Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5638acbc authored by menghanli's avatar menghanli
Browse files

Use HTML text preference for rich content

Implements for Color Correction, Color Inversion, and Magnify

Bug: 148837311
Test: Manual test
Change-Id: I5e5b311b6ae8e42cca3ef9048c8b8b0de52d13bc
parent 764e05dd
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -4822,7 +4822,7 @@
    <!-- Short summary for nav bar Magnification. Tells the user that this feature allows the user to magnify the screen using a button in the nav bar -->
    <string name="accessibility_screen_magnification_navbar_short_summary">Tap a button to zoom</string>
    <!-- Summary for the accessibility preference screen to enable screen magnification gestures. [CHAR LIMIT=none] -->
    <string name="accessibility_screen_magnification_summary">Quickly zoom in on the screen to see content more clearly.\n\n<b>To zoom in:</b>\n\t1. Use shortcut to start magnification\n\t2. Tap the screen\n\t3. Drag 2 fingers to move around screen\n\t4. Pinch with 2 fingers to adjust zoom\n\t5. Use shortcut to stop magnification</string>
    <string name="accessibility_screen_magnification_summary"><![CDATA[Quickly zoom in on the screen to see content more clearly.<br/><br/><b>To zoom in:</b><br/>\t1. Use shortcut to start magnification<br/>\t2. Tap the screen<br/>\t3. Drag 2 fingers to move around screen<br/>\t4. Pinch with 2 fingers to adjust zoom<br/>\t5. Use shortcut to stop magnification<br/><br/><b>To zoom in temporarily:</b><br/>\t1. Use shortcut to start magnification<br/>\t2. Touch & hold anywhere on the screen<br/>\t3. Drag finger to move around screen<br/>\t4. Lift finger to stop magnification]]></string>
    <!-- Summary for the accessibility preference screen to enable screen magnification via the nav bar. [CHAR LIMIT=none] -->
    <string name="accessibility_screen_magnification_navbar_summary">When magnification is turned on, you can zoom in on your screen.\n\n<b>To zoom</b>, start magnification, then tap anywhere on the screen.\n<ul><li>Drag 2 or more fingers to scroll</li>\n<li>Pinch 2 or more fingers to adjust zoom</li></ul>\n\n<b>To zoom temporarily</b>, start magnification, then touch &amp; hold anywhere on the screen.\n<ul><li>Drag to move around the screen</li>\n<li>Lift finger to zoom out</li></ul>\n\nYou can’t zoom in on the keyboard or navigation bar.</string>
    <!-- Title for the Accessibility tutorial dialog in Accessibility service with button. [CHAR LIMIT=50] -->
@@ -4932,7 +4932,7 @@
    <!-- Used in the accessibility service settings to control turning display color inversion on/off entirely. [CHAR LIMIT=NONE] -->
    <string name="accessibility_display_inversion_switch_title">Use color inversion</string>
    <!-- Subtitle for the accessibility preference to configure display color inversion. [CHAR LIMIT=NONE] -->
    <string name="accessibility_display_inversion_preference_subtitle">Color inversion turns light screens dark. This helps people who are sensitive to bright light see the screen more easily.\n\nNote: Dark colors will turn light. Colors will change in media and images. You can also use Dark theme (Settings > Display).</string>
    <string name="accessibility_display_inversion_preference_subtitle"><![CDATA[Color inversion turns light screens dark. This helps people who are sensitive to bright light see the screen more easily.<br/><br/>Note: Dark colors will turn light. Colors will change in media and images. You can also use Dark theme (Settings > Display).]]></string>
    <!-- Title for accessibility preference for configuring feature that performs click action soon after mouse/trackpad pointer stops moving. [CHAR LIMIT=NONE] -->
    <string name="accessibility_autoclick_preference_title">Auto click (dwell timing)</string>
    <!-- Footer text to explain what autoclick does -->
+0 −13
Original line number Diff line number Diff line
@@ -31,17 +31,4 @@
        settings:allowDividerBelow="true"
        settings:searchable="false" />

    <PreferenceCategory
        android:key="color_inversion_footer_category">

        <com.android.settingslib.widget.FooterPreference
            android:key="color_inversion_footer"
            android:persistent="false"
            android:selectable="false"
            settings:allowDividerAbove="false"
            android:title="@string/accessibility_display_inversion_preference_subtitle"
            settings:searchable="false" />

    </PreferenceCategory>

</PreferenceScreen>
+0 −12
Original line number Diff line number Diff line
@@ -52,16 +52,4 @@

    </PreferenceCategory>

    <PreferenceCategory
        android:key="daltonizer_footer_category">

        <com.android.settingslib.widget.FooterPreference
            android:key="daltonizer_footer"
            android:persistent="false"
            android:selectable="false"
            settings:allowDividerAbove="false"
            android:title="@string/accessibility_display_daltonizer_preference_subtitle"
            settings:searchable="false" />

    </PreferenceCategory>
</PreferenceScreen>
+2 −2
Original line number Diff line number Diff line
@@ -92,8 +92,8 @@ public class MagnificationGesturesPreferenceController extends TogglePreferenceC
                Settings.Secure.ACCESSIBILITY_DISPLAY_MAGNIFICATION_ENABLED);
        extras.putInt(AccessibilitySettings.EXTRA_TITLE_RES,
                R.string.accessibility_screen_magnification_gestures_title);
        extras.putInt(AccessibilitySettings.EXTRA_SUMMARY_RES,
                R.string.accessibility_screen_magnification_summary);
        extras.putCharSequence(AccessibilitySettings.EXTRA_HTML_DESCRIPTION,
                context.getText(R.string.accessibility_screen_magnification_summary));
        extras.putInt(AccessibilitySettings.EXTRA_VIDEO_RAW_RESOURCE_ID,
                R.raw.accessibility_screen_magnification);
    }
+2 −2
Original line number Diff line number Diff line
@@ -55,8 +55,8 @@ public class MagnificationNavbarPreferenceController extends TogglePreferenceCon
                    Settings.Secure.ACCESSIBILITY_DISPLAY_MAGNIFICATION_NAVBAR_ENABLED);
            extras.putInt(AccessibilitySettings.EXTRA_TITLE_RES,
                    R.string.accessibility_screen_magnification_navbar_title);
            extras.putInt(AccessibilitySettings.EXTRA_SUMMARY_RES,
                    R.string.accessibility_screen_magnification_navbar_summary);
            extras.putCharSequence(AccessibilitySettings.EXTRA_HTML_DESCRIPTION,
                    mContext.getText(R.string.accessibility_screen_magnification_navbar_summary));
            extras.putBoolean(AccessibilitySettings.EXTRA_CHECKED, isChecked());
            extras.putBoolean(AccessibilitySettings.EXTRA_LAUNCHED_FROM_SUW, mIsFromSUW);
        }
Loading