Change the Settings to app name with settings

Bug: 148837311
Test: Manual test
Change-Id: Ib27fd840c1a33378d9b301658b5d6c9ef148c615
diff --git a/res/values/strings.xml b/res/values/strings.xml
index e5e55c6..1e2e835 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -5077,9 +5077,12 @@
     <!-- Label describing a high intensity vibration option. [CHAR LIMIT=15] -->
     <string name="accessibility_vibration_intensity_high">High</string>
 
-    <!-- Title for accessibility menu item to lauch a settings activity. [CHAR LIMIT=15] -->
+    <!-- Title for accessibility menu item to launch a settings activity. [CHAR LIMIT=15] -->
     <string name="accessibility_menu_item_settings">Settings</string>
 
+    <!-- Title for accessibility menu item to launch a settings activity with app name. [CHAR LIMIT=30] -->
+    <string name="accessibility_service_menu_item_settings"><xliff:g example="TalkBack" id="accessibility_app_name">%1$s</xliff:g> settings</string>
+
     <!-- Summary for the enabled state of an accessibility feature. [CHAR LIMIT=10] -->
     <string name="accessibility_feature_state_on">On</string>
     <!-- Summary for the disabled state of an accessibility feature. [CHAR LIMIT=10] -->
diff --git a/src/com/android/settings/accessibility/AccessibilitySettings.java b/src/com/android/settings/accessibility/AccessibilitySettings.java
index 1722c99..6f51fd3 100644
--- a/src/com/android/settings/accessibility/AccessibilitySettings.java
+++ b/src/com/android/settings/accessibility/AccessibilitySettings.java
@@ -437,7 +437,8 @@
             final String settingsClassName = info.getSettingsActivityName();
             if (!TextUtils.isEmpty(settingsClassName)) {
                 extras.putString(EXTRA_SETTINGS_TITLE,
-                        getString(R.string.accessibility_menu_item_settings));
+                        getString(R.string.accessibility_service_menu_item_settings,
+                                resolveInfo.loadLabel(getPackageManager())));
                 extras.putString(EXTRA_SETTINGS_COMPONENT_NAME,
                         new ComponentName(packageName, settingsClassName).flattenToString());
             }