Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-dev
diff --git a/res/values/config.xml b/res/values/config.xml
index fd0063e..57d5a75 100755
--- a/res/values/config.xml
+++ b/res/values/config.xml
@@ -82,8 +82,16 @@
         -->
     </string-array>
 
+    <!-- List containing the component names of pre-installed captioning services. -->
+    <string-array name="config_preinstalled_captions_services" translatable="false">
+        <!--
+        <item>com.example.package.first/com.example.class.FirstService</item>
+        <item>com.example.package.second/com.example.class.SecondService</item>
+        -->
+    </string-array>
+
     <!-- List containing the component names of pre-installed audio and captioning services. -->
-    <string-array name="config_preinstalled_audio_and_caption_services" translatable="false">
+    <string-array name="config_preinstalled_audio_services" translatable="false">
         <!--
         <item>com.example.package.first/com.example.class.FirstService</item>
         <item>com.example.package.second/com.example.class.SecondService</item>
@@ -115,10 +123,23 @@
         -->
     </string-array>
 
+    <!-- List containing the order of services in captions category by preference key or
+         componentname. All preference keys in a category need to be specified to guarantee correct
+         behavior.-->
+    <string-array name="config_order_captions_services" translatable="false">
+        <!--
+        <item>com.example.package.first/com.example.class.FirstService</item>
+        <item>com.example.package.second/com.example.class.SecondService</item>
+        <item>captioning_preference_screen</item>
+        <item>rtt_setting</item>
+        <item>...</item>
+        -->
+    </string-array>
+
     <!-- List containing the order of services in audio and caption category by preference key
          or componentname. All preference keys in a category need to be specified to guarantee
          correct behavior.-->
-    <string-array name="config_order_audio_and_caption_services" translatable="false">
+    <string-array name="config_order_audio_services" translatable="false">
         <!--
         <item>com.example.package.first/com.example.class.FirstService</item>
         <item>com.example.package.second/com.example.class.SecondService</item>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index 4f12b79..1ac3a28 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -4963,8 +4963,10 @@
     <string name="vision_settings_suggestion_title">Change font size</string>
     <!-- Title for the accessibility preference category of screen reader services and settings. [CHAR LIMIT=50] -->
     <string name="screen_reader_category_title">Screen readers</string>
+    <!-- Title for the accessibility preference category of caption services and settings. [CHAR LIMIT=50] -->
+    <string name="captions_category_title">Captions</string>
     <!-- Title for the accessibility preference category of audio services and settings. [CHAR LIMIT=50] -->
-    <string name="audio_and_captions_category_title">Audio &amp; on-screen text</string>
+    <string name="audio_category_title">Audio</string>
     <!-- Title for the accessibility preference category of display services and settings. [CHAR LIMIT=50] -->
     <string name="display_category_title">Display</string>
     <!-- Title for the accessibility text options page. [CHAR LIMIT=50] -->
diff --git a/res/xml/accessibility_settings.xml b/res/xml/accessibility_settings.xml
index eff9e1d..67b1211 100644
--- a/res/xml/accessibility_settings.xml
+++ b/res/xml/accessibility_settings.xml
@@ -80,9 +80,9 @@
     </PreferenceCategory>
 
     <PreferenceCategory
-        android:key="audio_and_captions_category"
+        android:key="captions_category"
         android:persistent="false"
-        android:title="@string/audio_and_captions_category_title">
+        android:title="@string/captions_category_title">
 
         <Preference
             android:key="live_caption"
@@ -93,6 +93,26 @@
             settings:controller="com.android.settings.accessibility.LiveCaptionPreferenceController"/>
 
         <Preference
+            android:fragment="com.android.settings.accessibility.CaptionPropertiesFragment"
+            android:key="captioning_preference_screen"
+            android:persistent="false"
+            android:title="@string/accessibility_captioning_title"
+            settings:controller="com.android.settings.accessibility.CaptioningPreferenceController"/>
+
+        <Preference
+            android:key="rtt_setting"
+            android:summary="@string/summary_placeholder"
+            android:title="@string/rtt_settings_title"
+            settings:controller="com.android.settings.accessibility.RTTSettingPreferenceController"/>
+
+    </PreferenceCategory>
+
+    <PreferenceCategory
+        android:key="audio_category"
+        android:persistent="false"
+        android:title="@string/audio_category_title">
+
+        <Preference
             android:key="hearing_aid_preference"
             android:persistent="false"
             android:summary="@string/accessibility_hearingaid_not_connected_summary"
@@ -106,19 +126,6 @@
             android:title="@string/accessibility_audio_adjustment_title"
             settings:searchable="true"/>
 
-        <Preference
-            android:key="rtt_setting"
-            android:summary="@string/summary_placeholder"
-            android:title="@string/rtt_settings_title"
-            settings:controller="com.android.settings.accessibility.RTTSettingPreferenceController"/>
-
-        <Preference
-            android:fragment="com.android.settings.accessibility.CaptionPropertiesFragment"
-            android:key="captioning_preference_screen"
-            android:persistent="false"
-            android:title="@string/accessibility_captioning_title"
-            settings:controller="com.android.settings.accessibility.CaptioningPreferenceController"/>
-
     </PreferenceCategory>
 
     <!-- TODO(b/174829936): Add title for shortcuts settings category. -->
@@ -140,19 +147,4 @@
 
     </PreferenceCategory>
 
-    <PreferenceCategory
-        android:key="experimental_category"
-        android:persistent="false"
-        android:title="@string/experimental_category_title"
-        settings:initialExpandedChildrenCount="1">
-
-        <SwitchPreference
-            android:key="accessibility_shortcut_preference"
-            android:persistent="false"
-            android:title="@string/accessibility_shortcut_service_on_lock_screen_title"
-            android:summary="@string/accessibility_shortcut_description"
-            settings:controller="com.android.settings.accessibility.AccessibilityShortcutPreferenceController"/>
-
-    </PreferenceCategory>
-
 </PreferenceScreen>
diff --git a/src/com/android/settings/accessibility/AccessibilitySettings.java b/src/com/android/settings/accessibility/AccessibilitySettings.java
index 582111f..d510ac7 100644
--- a/src/com/android/settings/accessibility/AccessibilitySettings.java
+++ b/src/com/android/settings/accessibility/AccessibilitySettings.java
@@ -73,15 +73,15 @@
 
     // Preference categories
     private static final String CATEGORY_SCREEN_READER = "screen_reader_category";
-    private static final String CATEGORY_AUDIO_AND_CAPTIONS = "audio_and_captions_category";
+    private static final String CATEGORY_CAPTIONS = "captions_category";
+    private static final String CATEGORY_AUDIO = "audio_category";
     private static final String CATEGORY_DISPLAY = "display_category";
     private static final String CATEGORY_INTERACTION_CONTROL = "interaction_control_category";
-    private static final String CATEGORY_EXPERIMENTAL = "experimental_category";
     private static final String CATEGORY_DOWNLOADED_SERVICES = "user_installed_services_category";
 
     private static final String[] CATEGORIES = new String[]{
-            CATEGORY_SCREEN_READER, CATEGORY_AUDIO_AND_CAPTIONS, CATEGORY_DISPLAY,
-            CATEGORY_INTERACTION_CONTROL, CATEGORY_EXPERIMENTAL, CATEGORY_DOWNLOADED_SERVICES
+            CATEGORY_SCREEN_READER, CATEGORY_CAPTIONS, CATEGORY_AUDIO, CATEGORY_DISPLAY,
+            CATEGORY_INTERACTION_CONTROL, CATEGORY_DOWNLOADED_SERVICES
     };
 
     // Preferences
@@ -330,8 +330,10 @@
 
         initializePreBundledServicesMapFromArray(CATEGORY_SCREEN_READER,
                 R.array.config_preinstalled_screen_reader_services);
-        initializePreBundledServicesMapFromArray(CATEGORY_AUDIO_AND_CAPTIONS,
-                R.array.config_preinstalled_audio_and_caption_services);
+        initializePreBundledServicesMapFromArray(CATEGORY_CAPTIONS,
+                R.array.config_preinstalled_captions_services);
+        initializePreBundledServicesMapFromArray(CATEGORY_AUDIO,
+                R.array.config_preinstalled_audio_services);
         initializePreBundledServicesMapFromArray(CATEGORY_DISPLAY,
                 R.array.config_preinstalled_display_services);
         initializePreBundledServicesMapFromArray(CATEGORY_INTERACTION_CONTROL,
@@ -359,8 +361,10 @@
         // Update the order of all the category according to the order defined in xml file.
         updateCategoryOrderFromArray(CATEGORY_SCREEN_READER,
                 R.array.config_order_screen_reader_services);
-        updateCategoryOrderFromArray(CATEGORY_AUDIO_AND_CAPTIONS,
-                R.array.config_order_audio_and_caption_services);
+        updateCategoryOrderFromArray(CATEGORY_CAPTIONS,
+                R.array.config_order_captions_services);
+        updateCategoryOrderFromArray(CATEGORY_AUDIO,
+                R.array.config_order_audio_services);
         updateCategoryOrderFromArray(CATEGORY_INTERACTION_CONTROL,
                 R.array.config_order_interaction_control_services);
         updateCategoryOrderFromArray(CATEGORY_DISPLAY,