Implemented new preference setting screen for face based auto-rotation

Test: locally with phone and make -j64 RunSettingsRoboTests
ROBOTEST_FILTER="com.android.settings.display.SmartAutoRotatePreferenceControllerTest"

Bug: 172857585
Change-Id: I8aaeb9d726ff71f64fd241c01fe2a1268fff927e
This commit is contained in:
Abel Tesfaye
2020-11-19 20:37:20 +00:00
parent 5f20dd4ce2
commit a96775c58b
9 changed files with 612 additions and 1 deletions

View File

@@ -97,6 +97,15 @@
<!-- Description for the button that makes interface elements larger. [CHAR_LIMIT=NONE] -->
<string name="font_size_make_larger_desc">Make larger</string>
<!-- Auto rotate switchbar title. [CHAR_LIMIT=NONE] -->
<string name="auto_rotate_settings_primary_switch_title">Use Auto-Rotate</string>
<!-- Disclaimer for camera based rotate [CHAR_LIMIT=NONE] -->
<string name="smart_rotate_text_headline">
Face based Autorotate uses the front camera to see if and how someone is looking at the screen. It allows
for reading while lying down and images are never stored or sent to Google.&lt;br>&lt;br>
&lt;a href="<xliff:g example="http://www.google.com" id="url">http://support.google.com/mobile?p=telephony_rtt</xliff:g>">Learn more&lt;/a>
</string>
<string name="font_size_preview_text_headline">Sample text</string>
<string name="font_size_preview_text_title"
translation_description="Title text in sample text used to illustrate how the currently selected font size will appear to the user. NOTE: Translate manually. No not adopt any copyrighted material for translation.">
@@ -2704,8 +2713,18 @@
<!-- Display settings --><skip/>
<!-- Sound & display settings screen, section header for settings related to display -->
<string name="display_settings">Display</string>
<!-- Sound & display settings screen, section header for settings related to display -->
<string name="rotate_settings_class" translatable="false">com.android.settings.DisplaySettings</string>
<!-- Sound & display settings screen, accelerometer-based rotation check box label -->
<string name="accelerometer_title">Auto-rotate screen</string>
<!-- Sound & display settings screen, locked rotation check box label [CHAR LIMIT=30] -->
<string name="auto_rotate_option_off">Off</string>
<!-- Sound & display settings screen, accelerometer-based rotation check box label [CHAR LIMIT=30] -->
<string name="auto_rotate_option_on">On</string>
<!-- Sound & display settings screen, face-based rotation check box label [CHAR LIMIT=30] -->
<string name="auto_rotate_option_face_based">On - Face-based</string>
<!-- SmartAutoRotatePreferenceFragment settings screen, face-based rotation switch label [CHAR LIMIT=30] -->
<string name="auto_rotate_switch_face_based">Enable Face Detection</string>
<!-- Display settings screen, Color mode settings title [CHAR LIMIT=30] -->
<string name="color_mode_title">Colors</string>
<!-- Display settings screen, Color mode option for "natural(sRGB) color" [CHAR LIMIT=45] -->