-Added accessibility caption style and text color resolver.

-Added button to open captioning settings activity from appearance settings.
-Modified player captions to use custom caption style when captioning manager is enabled.
-Removed caption size settings from appearance settings.
This commit is contained in:
John Zhen Mo 2018-04-08 13:58:18 -07:00
parent c3c22f3a4a
commit a8a94602c2
8 changed files with 86 additions and 53 deletions

View file

@ -109,23 +109,7 @@
</string-array>
<!-- Caption Size -->
<string name="caption_size_key" translatable="false">caption_size_key</string>
<string name="caption_size_default" translatable="false">@string/normal_caption_size_key</string>
<string name="smaller_caption_size_key" translatable="false">smaller_caption_size</string>
<string name="normal_caption_size_key" translatable="false">normal_caption_size</string>
<string name="larger_caption_size_key" translatable="false">larger_caption_size</string>
<string-array name="caption_size_descriptions_list" translatable="false">
<item>@string/smaller_caption_font_size</item>
<item>@string/normal_caption_font_size</item>
<item>@string/larger_caption_font_size</item>
</string-array>
<string-array name="caption_size_values_list" translatable="false">
<item>@string/smaller_caption_size_key</item>
<item>@string/normal_caption_size_key</item>
<item>@string/larger_caption_size_key</item>
</string-array>
<string name="caption_settings_key" translatable="false">caption_settings_key</string>
<!-- Content & History -->
<string name="show_search_suggestions_key" translatable="false">show_search_suggestions</string>

View file

@ -425,10 +425,10 @@
<string name="resize_zoom">ZOOM</string>
<string name="caption_auto_generated">Auto-generated</string>
<string name="caption_font_size_settings_title">Caption font size</string>
<string name="smaller_caption_font_size">Smaller font</string>
<string name="normal_caption_font_size">Normal font</string>
<string name="larger_caption_font_size">Larger font</string>
<!-- Caption Settings -->
<string name="caption_setting_title">Caption</string>
<string name="caption_setting_description">Modify player caption text scale and background styles. Require player restart to take effect.</string>
<!-- Debug Settings -->
<string name="enable_leak_canary_title">Enable LeakCanary</string>

View file

@ -22,11 +22,8 @@
android:title="@string/show_hold_to_append_title"
android:summary="@string/show_hold_to_append_summary"/>
<ListPreference
android:defaultValue="@string/caption_size_default"
android:entries="@array/caption_size_descriptions_list"
android:entryValues="@array/caption_size_values_list"
android:key="@string/caption_size_key"
android:summary="%s"
android:title="@string/caption_font_size_settings_title"/>
<Preference
android:key="@string/caption_settings_key"
android:title="@string/caption_setting_title"
android:summary="@string/caption_setting_description"/>
</PreferenceScreen>