diff --git a/res/values/strings.xml b/res/values/strings.xml
index 56856b6..de733b8 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -1236,8 +1236,10 @@
     <string name="private_space_category_ways_to_unlock">Ways to unlock</string>
     <!-- Summary for one lock when device screen lock is used as private profile lock. [CHAR LIMIT=40] -->
     <string name="private_space_screen_lock_summary">Same as device screen lock</string>
-    <!-- Dialog message to choose a new lock for Private Space. [CHAR LIMIT=50] -->
+    <!-- Dialog title to choose a new lock for Private Space. [CHAR LIMIT=50] -->
     <string name="private_space_new_lock_title">Choose a new lock for private space?</string>
+    <!-- Dialog message mentioning device PIN, pattern or password needs to be entered on the next screen. [CHAR LIMIT=NONE] -->
+    <string name="private_space_new_lock_message">You\’ll need to enter your device PIN, pattern, or password on the next screen</string>
     <!-- Title for the preference for auto lock private space and auto lock private space settings page. [CHAR LIMIT=50] -->
     <string name="private_space_auto_lock_title">Lock private space automatically</string>
     <!-- Description for private space auto lock settings page. [CHAR LIMIT=NONE] -->
@@ -1248,28 +1250,26 @@
     <string name="private_space_auto_lock_after_inactivity">After 5 minutes of inactivity</string>
     <!-- Configure auto lock: Value for auto lock configuration to never lock private space. [CHAR LIMIT=20] -->
     <string name="private_space_auto_lock_never">Never</string>
-    <!-- Title for the preference to hide Private Space. [CHAR LIMIT=60] -->
-    <string name="private_space_hide_title">Hide when locked</string>
-    <!-- Title for the hide Private Space setting. [CHAR LIMIT=60] -->
-    <string name="privatespace_hide_page_title">Hide private space when locked</string>
+    <!-- Title for the settings preference and settings page for hide private space when locked setting. [CHAR LIMIT=60] -->
+    <string name="private_space_hide_page_title">Hide private space when it\'s locked</string>
     <!-- Description for hide Private Space settings page. [CHAR LIMIT=NONE] -->
-    <string name="privatespace_hide_page_summary">To stop other people knowing you have a private space on your device, you can hide it from your apps list</string>
+    <string name="private_space_hide_page_summary">To stop other people knowing you have a private space on your device, you can hide it from your apps list</string>
     <!-- Header in hide Private Space settings page to access Private Space when hidden. [CHAR LIMIT=60] -->
-    <string name="privatespace_access_header">Access private space when hidden</string>
+    <string name="private_space_access_header">Access private space when hidden</string>
     <!-- Text in hide Private Space settings page on how to search Private Space when hidden. [CHAR LIMIT=90] -->
-    <string name="privatespace_search_description">From your apps list, enter \"private space\" in the search bar</string>
+    <string name="private_space_search_description">In the search bar, enter \"private space\"</string>
     <!-- Text in hide Private Space settings page to tap on Private Space tile. [CHAR LIMIT=60] -->
-    <string name="privatespace_tap_tile_description">Tap the private space tile</string>
+    <string name="private_space_tap_tile_description">Tap <b>Private space</b></string>
     <!-- Text in hide Private Space settings page to Unlock Private Space. [CHAR LIMIT=60] -->
-    <string name="privatespace_unlock_description">Unlock your private space</string>
+    <string name="private_space_unlock_description">Unlock your private space</string>
     <!-- Used to describe the off state of Private space hidden [CHAR LIMIT=30] -->
-    <string name="privatespace_hide_off_summary">Off</string>
+    <string name="private_space_hide_off_summary">Off</string>
     <!-- Used to describe the off state of Private space hidden [CHAR LIMIT=30] -->
-    <string name="privatespace_hide_on_summary">On</string>
+    <string name="private_space_hide_on_summary">On</string>
     <!-- Title for the dialog shown when Private space hidden setting is turned on. [CHAR LIMIT=60] -->
-    <string name="private_space_hide_dialog_title">Private space will hide when you lock it next</string>
+    <string name="private_space_hide_dialog_title">Private space will hide the next time you lock it</string>
     <!-- Text message in the dialog shown when Private space hidden setting is turned on. [CHAR LIMIT=90] -->
-    <string name="private_space_hide_dialog_message">To access your space when it’s hidden, enter \“private space\” in the search bar on your apps list</string>
+    <string name="private_space_hide_dialog_message">To access private space, enter \“private space\” in the search bar from your apps list.</string>
     <!-- Label for the dialog shown when Private space hidden setting is turned on. [CHAR LIMIT=90] -->
     <string name="private_space_hide_dialog_button">Got it</string>
     <!-- System category for the Private Space page. [CHAR LIMIT=30] -->
@@ -2860,7 +2860,7 @@
     <!-- Dark UI screen footer action text shown when the when Dark theme turns on/off automatically according to a user bedtime schedule. [CHAR LIMIT=NONE] -->
     <string name="dark_ui_bedtime_footer_action">Bedtime mode settings</string>
     <!-- Even Dimmer setting title. Allows device to reduce brightness even further than standard range. [CHAR LIMIT=NONE] -->
-    <string name="even_dimmer_display_title">Even Dimmer</string>
+    <string name="even_dimmer_display_title">Even dimmer</string>
     <!-- Even Dimmer setting summary. [CHAR LIMIT=NONE] -->
     <string name="even_dimmer_display_summary">Allow device to go dimmer than usual</string>
 
diff --git a/res/xml/private_space_hide_locked.xml b/res/xml/private_space_hide_locked.xml
index cd1c406..4c83e84 100644
--- a/res/xml/private_space_hide_locked.xml
+++ b/res/xml/private_space_hide_locked.xml
@@ -16,7 +16,7 @@
 <PreferenceScreen
     xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:settings="http://schemas.android.com/apk/res-auto"
-    android:title="@string/privatespace_hide_page_title">
+    android:title="@string/private_space_hide_page_title">
 
     <com.android.settingslib.widget.IllustrationPreference
         android:key="privatespace_hide_video"
@@ -25,36 +25,36 @@
 
     <com.android.settingslib.widget.MainSwitchPreference
         android:key="hide_when_locked"
-        android:title="@string/privatespace_hide_page_title"
+        android:title="@string/private_space_hide_page_title"
         settings:controller="com.android.settings.privatespace.HidePrivateSpaceController"/>
 
         <Preference
         android:key="private_space_hidden"
-        android:summary="@string/privatespace_hide_page_summary"
+        android:summary="@string/private_space_hide_page_summary"
         android:selectable="false"
         settings:searchable="false" />
 
     <PreferenceCategory
-        android:title="@string/privatespace_access_header">
+        android:title="@string/private_space_access_header">
 
         <Preference
         android:key="search_when_locked_footer"
         android:icon="@drawable/counter_1_24dp"
-        android:title="@string/privatespace_search_description"
+        android:title="@string/private_space_search_description"
         android:selectable="false"
         settings:searchable="false" />
 
         <Preference
             android:key="tap_tile_footer"
             android:icon="@drawable/counter_2_24dp"
-            android:title="@string/privatespace_tap_tile_description"
+            android:title="@string/private_space_tap_tile_description"
             android:selectable="false"
             settings:searchable="false" />
 
         <Preference
             android:key="unlock_profile_footer"
             android:icon="@drawable/counter_3_24dp"
-            android:title="@string/privatespace_unlock_description"
+            android:title="@string/private_space_unlock_description"
             android:selectable="false"
             settings:searchable="false" />
 
diff --git a/res/xml/private_space_settings.xml b/res/xml/private_space_settings.xml
index 86537cc..f979599 100644
--- a/res/xml/private_space_settings.xml
+++ b/res/xml/private_space_settings.xml
@@ -52,7 +52,7 @@
 
         <Preference
             android:key="private_space_hidden"
-            android:title="@string/private_space_hide_title"
+            android:title="@string/private_space_hide_page_title"
             android:fragment="com.android.settings.privatespace.HidePrivateSpaceSettings"
             settings:controller="com.android.settings.privatespace.HidePrivateSpaceSummaryController"
             settings:searchable="false" />
diff --git a/src/com/android/settings/accessibility/AccessibilityServiceWarning.java b/src/com/android/settings/accessibility/AccessibilityServiceWarning.java
deleted file mode 100644
index fb50ef1..0000000
--- a/src/com/android/settings/accessibility/AccessibilityServiceWarning.java
+++ /dev/null
@@ -1,155 +0,0 @@
-/*
- * Copyright (C) 2016 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.android.settings.accessibility;
-
-import static android.view.WindowManager.LayoutParams.SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS;
-
-import android.accessibilityservice.AccessibilityServiceInfo;
-import android.app.Dialog;
-import android.content.Context;
-import android.content.DialogInterface;
-import android.graphics.drawable.Drawable;
-import android.text.BidiFormatter;
-import android.view.LayoutInflater;
-import android.view.MotionEvent;
-import android.view.View;
-import android.view.Window;
-import android.view.WindowManager;
-import android.widget.Button;
-import android.widget.ImageView;
-import android.widget.TextView;
-import android.widget.Toast;
-
-import androidx.annotation.NonNull;
-import androidx.appcompat.app.AlertDialog;
-import androidx.core.content.ContextCompat;
-
-import com.android.settings.R;
-
-import java.util.Locale;
-
-/**
- * Utility class for creating the dialog that asks users for explicit permission for an
- * accessibility service to access user data before the service is enabled
- */
-public class AccessibilityServiceWarning {
-    private static final View.OnTouchListener filterTouchListener = (View v, MotionEvent event) -> {
-        // Filter obscured touches by consuming them.
-        if (((event.getFlags() & MotionEvent.FLAG_WINDOW_IS_OBSCURED) != 0)
-                || ((event.getFlags() & MotionEvent.FLAG_WINDOW_IS_PARTIALLY_OBSCURED) != 0)) {
-            if (event.getAction() == MotionEvent.ACTION_UP) {
-                Toast.makeText(v.getContext(), R.string.touch_filtered_warning,
-                        Toast.LENGTH_SHORT).show();
-            }
-            return true;
-        }
-        return false;
-    };
-
-    /**
-     * The interface to execute the uninstallation action.
-     */
-    interface UninstallActionPerformer {
-        void uninstallPackage();
-    }
-
-    /**
-     * Returns a {@link Dialog} to be shown to confirm that they want to enable a service.
-     * @deprecated Use {@link com.android.internal.accessibility.dialog.AccessibilityServiceWarning}
-     */
-    @Deprecated
-    public static Dialog createCapabilitiesDialog(@NonNull Context context,
-            @NonNull AccessibilityServiceInfo info, @NonNull View.OnClickListener listener,
-            @NonNull UninstallActionPerformer performer) {
-        final AlertDialog ad = new AlertDialog.Builder(context)
-                .setView(createEnableDialogContentView(context, info, listener, performer))
-                .create();
-
-        Window window = ad.getWindow();
-        WindowManager.LayoutParams params = window.getAttributes();
-        params.privateFlags |= SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS;
-        window.setAttributes(params);
-        ad.create();
-        ad.setCanceledOnTouchOutside(true);
-
-        return ad;
-    }
-
-    private static View createEnableDialogContentView(Context context,
-            @NonNull AccessibilityServiceInfo info, View.OnClickListener listener,
-            UninstallActionPerformer performer) {
-        LayoutInflater inflater = (LayoutInflater) context.getSystemService(
-                Context.LAYOUT_INFLATER_SERVICE);
-
-        View content = inflater.inflate(R.layout.enable_accessibility_service_dialog_content,
-                null);
-
-        final Drawable icon;
-        if (info.getResolveInfo().getIconResource() == 0) {
-            icon = ContextCompat.getDrawable(context, R.drawable.ic_accessibility_generic);
-        } else {
-            icon = info.getResolveInfo().loadIcon(context.getPackageManager());
-        }
-
-        ImageView permissionDialogIcon = content.findViewById(
-                R.id.permissionDialog_icon);
-        permissionDialogIcon.setImageDrawable(icon);
-
-        TextView permissionDialogTitle = content.findViewById(R.id.permissionDialog_title);
-        permissionDialogTitle.setText(context.getString(R.string.enable_service_title,
-                getServiceName(context, info)));
-
-        Button permissionAllowButton = content.findViewById(
-                R.id.permission_enable_allow_button);
-        Button permissionDenyButton = content.findViewById(
-                R.id.permission_enable_deny_button);
-        permissionAllowButton.setOnClickListener(listener);
-        permissionAllowButton.setOnTouchListener(filterTouchListener);
-        permissionDenyButton.setOnClickListener(listener);
-
-        final Button uninstallButton = content.findViewById(
-                R.id.permission_enable_uninstall_button);
-        // Shows an uninstall button to help users quickly remove the non-system App due to the
-        // required permissions.
-        if (!AccessibilityUtil.isSystemApp(info)) {
-            uninstallButton.setVisibility(View.VISIBLE);
-            uninstallButton.setOnClickListener(v -> performer.uninstallPackage());
-        }
-        return content;
-    }
-
-    /** Returns a {@link Dialog} to be shown to confirm that they want to disable a service. */
-    public static Dialog createDisableDialog(Context context,
-            AccessibilityServiceInfo info, DialogInterface.OnClickListener listener) {
-        CharSequence serviceName = getServiceName(context, info);
-
-        return new AlertDialog.Builder(context)
-                .setTitle(context.getString(R.string.disable_service_title, serviceName))
-                .setCancelable(true)
-                .setPositiveButton(R.string.accessibility_dialog_button_stop, listener)
-                .setNegativeButton(R.string.accessibility_dialog_button_cancel, listener)
-                .create();
-    }
-
-    // Get the service name and bidi wrap it to protect from bidi side effects.
-    private static CharSequence getServiceName(Context context, AccessibilityServiceInfo info) {
-        final Locale locale = context.getResources().getConfiguration().getLocales().get(0);
-        final CharSequence label =
-                info.getResolveInfo().loadLabel(context.getPackageManager());
-        return BidiFormatter.getInstance(locale).unicodeWrap(label);
-    }
-}
diff --git a/src/com/android/settings/accessibility/InvisibleToggleAccessibilityServicePreferenceFragment.java b/src/com/android/settings/accessibility/InvisibleToggleAccessibilityServicePreferenceFragment.java
index 21ac998..eb7b27d 100644
--- a/src/com/android/settings/accessibility/InvisibleToggleAccessibilityServicePreferenceFragment.java
+++ b/src/com/android/settings/accessibility/InvisibleToggleAccessibilityServicePreferenceFragment.java
@@ -18,9 +18,7 @@
 
 import android.accessibilityservice.AccessibilityServiceInfo;
 import android.content.DialogInterface;
-import android.view.View;
 
-import com.android.settings.R;
 import com.android.settingslib.accessibility.AccessibilityUtils;
 
 /**
@@ -52,7 +50,6 @@
         super.onToggleClicked(preference);
         boolean enabled = getArguments().getBoolean(AccessibilitySettings.EXTRA_CHECKED)
                 && preference.isChecked();
-
         AccessibilityUtils.setAccessibilityServiceState(getContext(), mComponentName, enabled);
     }
 
@@ -62,27 +59,9 @@
      * Enables accessibility service when user clicks permission allow button.
      */
     @Override
-    void onDialogButtonFromShortcutToggleClicked(View view) {
-        super.onDialogButtonFromShortcutToggleClicked(view);
-        if (!android.view.accessibility.Flags.cleanupAccessibilityWarningDialog()) {
-            if (view.getId() == R.id.permission_enable_allow_button) {
-                AccessibilityUtils.setAccessibilityServiceState(getContext(), mComponentName,
-                        true);
-            }
-        }
-    }
-
-    /**
-     * {@inheritDoc}
-     *
-     * Enables accessibility service when user clicks permission allow button.
-     */
-    @Override
     void onAllowButtonFromShortcutToggleClicked() {
         super.onAllowButtonFromShortcutToggleClicked();
-        if (android.view.accessibility.Flags.cleanupAccessibilityWarningDialog()) {
-            AccessibilityUtils.setAccessibilityServiceState(getContext(), mComponentName, true);
-        }
+        AccessibilityUtils.setAccessibilityServiceState(getContext(), mComponentName, true);
     }
 
     /**
diff --git a/src/com/android/settings/accessibility/ReduceBrightColorsPreferenceController.java b/src/com/android/settings/accessibility/ReduceBrightColorsPreferenceController.java
index 7b40024..3ca089c 100644
--- a/src/com/android/settings/accessibility/ReduceBrightColorsPreferenceController.java
+++ b/src/com/android/settings/accessibility/ReduceBrightColorsPreferenceController.java
@@ -32,6 +32,7 @@
 import androidx.preference.Preference;
 import androidx.preference.PreferenceScreen;
 
+import com.android.server.display.feature.flags.Flags;
 import com.android.settings.R;
 import com.android.settingslib.PrimarySwitchPreference;
 import com.android.settingslib.core.lifecycle.LifecycleObserver;
@@ -88,6 +89,15 @@
 
     @Override
     public int getAvailabilityStatus() {
+        // Successor to this feature is Even Dimmer
+        // found in display/EvenDimmerPreferenceController
+        // Only allow RBC if even dimmer is not possible on this device
+        if (Flags.evenDimmer() && mContext.getResources().getBoolean(
+                com.android.internal.R.bool.config_evenDimmerEnabled)) {
+            return UNSUPPORTED_ON_DEVICE;
+        }
+
+
         return ColorDisplayManager.isReduceBrightColorsAvailable(mContext) ? AVAILABLE
                 : UNSUPPORTED_ON_DEVICE;
     }
diff --git a/src/com/android/settings/accessibility/ToggleAccessibilityServicePreferenceFragment.java b/src/com/android/settings/accessibility/ToggleAccessibilityServicePreferenceFragment.java
index e89ff94..72e1ad8 100644
--- a/src/com/android/settings/accessibility/ToggleAccessibilityServicePreferenceFragment.java
+++ b/src/com/android/settings/accessibility/ToggleAccessibilityServicePreferenceFragment.java
@@ -21,6 +21,7 @@
 import static com.android.settings.accessibility.PreferredShortcuts.retrieveUserShortcutType;
 
 import android.accessibilityservice.AccessibilityServiceInfo;
+import android.app.AlertDialog;
 import android.app.Dialog;
 import android.app.settings.SettingsEnums;
 import android.content.BroadcastReceiver;
@@ -35,6 +36,7 @@
 import android.net.Uri;
 import android.os.Bundle;
 import android.os.SystemClock;
+import android.text.BidiFormatter;
 import android.text.TextUtils;
 import android.util.Log;
 import android.view.Menu;
@@ -52,6 +54,7 @@
 import com.android.settingslib.accessibility.AccessibilityUtils;
 
 import java.util.List;
+import java.util.Locale;
 import java.util.concurrent.atomic.AtomicBoolean;
 
 /** Fragment for providing toggle bar and basic accessibility service setup. */
@@ -158,69 +161,63 @@
                 if (info == null) {
                     return null;
                 }
-                if (android.view.accessibility.Flags.cleanupAccessibilityWarningDialog()) {
-                    mWarningDialog =
-                            com.android.internal.accessibility.dialog.AccessibilityServiceWarning
-                                    .createAccessibilityServiceWarningDialog(getPrefContext(), info,
-                                            v -> onAllowButtonFromEnableToggleClicked(),
-                                            v -> onDenyButtonFromEnableToggleClicked(),
-                                            v -> onDialogButtonFromUninstallClicked());
-                } else {
-                    mWarningDialog = AccessibilityServiceWarning
-                            .createCapabilitiesDialog(getPrefContext(), info,
-                                    this::onDialogButtonFromEnableToggleClicked,
-                                    this::onDialogButtonFromUninstallClicked);
-                }
+                mWarningDialog =
+                        com.android.internal.accessibility.dialog.AccessibilityServiceWarning
+                                .createAccessibilityServiceWarningDialog(getPrefContext(), info,
+                                        v -> onAllowButtonFromEnableToggleClicked(),
+                                        v -> onDenyButtonFromEnableToggleClicked(),
+                                        v -> onDialogButtonFromUninstallClicked());
                 return mWarningDialog;
             case DialogEnums.ENABLE_WARNING_FROM_SHORTCUT_TOGGLE:
                 if (info == null) {
                     return null;
                 }
-                if (android.view.accessibility.Flags.cleanupAccessibilityWarningDialog()) {
-                    mWarningDialog =
-                            com.android.internal.accessibility.dialog.AccessibilityServiceWarning
-                                    .createAccessibilityServiceWarningDialog(getPrefContext(), info,
-                                            v -> onAllowButtonFromShortcutToggleClicked(),
-                                            v -> onDenyButtonFromShortcutToggleClicked(),
-                                            v -> onDialogButtonFromUninstallClicked());
-                } else {
-                    mWarningDialog = AccessibilityServiceWarning
-                            .createCapabilitiesDialog(getPrefContext(), info,
-                                    this::onDialogButtonFromShortcutToggleClicked,
-                                    this::onDialogButtonFromUninstallClicked);
-                }
+                mWarningDialog =
+                        com.android.internal.accessibility.dialog.AccessibilityServiceWarning
+                                .createAccessibilityServiceWarningDialog(getPrefContext(), info,
+                                        v -> onAllowButtonFromShortcutToggleClicked(),
+                                        v -> onDenyButtonFromShortcutToggleClicked(),
+                                        v -> onDialogButtonFromUninstallClicked());
                 return mWarningDialog;
             case DialogEnums.ENABLE_WARNING_FROM_SHORTCUT:
                 if (info == null) {
                     return null;
                 }
-                if (android.view.accessibility.Flags.cleanupAccessibilityWarningDialog()) {
-                    mWarningDialog =
-                            com.android.internal.accessibility.dialog.AccessibilityServiceWarning
-                                    .createAccessibilityServiceWarningDialog(getPrefContext(), info,
-                                            v -> onAllowButtonFromShortcutClicked(),
-                                            v -> onDenyButtonFromShortcutClicked(),
-                                            v -> onDialogButtonFromUninstallClicked());
-                } else {
-                    mWarningDialog = AccessibilityServiceWarning
-                            .createCapabilitiesDialog(getPrefContext(), info,
-                                    this::onDialogButtonFromShortcutClicked,
-                                    this::onDialogButtonFromUninstallClicked);
-                }
+                mWarningDialog =
+                        com.android.internal.accessibility.dialog.AccessibilityServiceWarning
+                                .createAccessibilityServiceWarningDialog(getPrefContext(), info,
+                                        v -> onAllowButtonFromShortcutClicked(),
+                                        v -> onDenyButtonFromShortcutClicked(),
+                                        v -> onDialogButtonFromUninstallClicked());
                 return mWarningDialog;
             case DialogEnums.DISABLE_WARNING_FROM_TOGGLE:
                 if (info == null) {
                     return null;
                 }
-                mWarningDialog = AccessibilityServiceWarning
-                        .createDisableDialog(getPrefContext(), info,
-                                this::onDialogButtonFromDisableToggleClicked);
+                mWarningDialog = createDisableDialog(
+                        getPrefContext(), info, this::onDialogButtonFromDisableToggleClicked);
                 return mWarningDialog;
             default:
                 return super.onCreateDialog(dialogId);
         }
     }
 
+    /** Returns a {@link Dialog} to be shown to confirm that they want to disable a service. */
+    private static Dialog createDisableDialog(Context context,
+            AccessibilityServiceInfo info, DialogInterface.OnClickListener listener) {
+        final Locale locale = context.getResources().getConfiguration().getLocales().get(0);
+        final CharSequence label =
+                info.getResolveInfo().loadLabel(context.getPackageManager());
+        CharSequence serviceName = BidiFormatter.getInstance(locale).unicodeWrap(label);
+
+        return new AlertDialog.Builder(context)
+                .setTitle(context.getString(R.string.disable_service_title, serviceName))
+                .setCancelable(true)
+                .setPositiveButton(R.string.accessibility_dialog_button_stop, listener)
+                .setNegativeButton(R.string.accessibility_dialog_button_cancel, listener)
+                .create();
+    }
+
     @Override
     public int getDialogMetricsCategory(int dialogId) {
         switch (dialogId) {
@@ -333,13 +330,9 @@
         final int shortcutTypes = retrieveUserShortcutType(getPrefContext(),
                 mComponentName.flattenToString(), getDefaultShortcutTypes());
         if (preference.isChecked()) {
-            final boolean isWarningRequired;
-            if (android.view.accessibility.Flags.cleanupAccessibilityWarningDialog()) {
-                isWarningRequired = getPrefContext().getSystemService(AccessibilityManager.class)
-                        .isAccessibilityServiceWarningRequired(getAccessibilityServiceInfo());
-            } else {
-                isWarningRequired = !mToggleServiceSwitchPreference.isChecked();
-            }
+            final boolean isWarningRequired =
+                    getPrefContext().getSystemService(AccessibilityManager.class)
+                            .isAccessibilityServiceWarningRequired(getAccessibilityServiceInfo());
             if (isWarningRequired) {
                 preference.setChecked(false);
                 showPopupDialog(DialogEnums.ENABLE_WARNING_FROM_SHORTCUT_TOGGLE);
@@ -355,15 +348,9 @@
 
     @Override
     public void onSettingsClicked(ShortcutPreference preference) {
-        final boolean isWarningRequired;
-        if (android.view.accessibility.Flags.cleanupAccessibilityWarningDialog()) {
-            isWarningRequired = getPrefContext().getSystemService(AccessibilityManager.class)
-                    .isAccessibilityServiceWarningRequired(getAccessibilityServiceInfo());
-        } else {
-            isWarningRequired = !(mShortcutPreference.isChecked()
-                    || mToggleServiceSwitchPreference.isChecked());
-        }
-
+        final boolean isWarningRequired =
+                getPrefContext().getSystemService(AccessibilityManager.class)
+                        .isAccessibilityServiceWarningRequired(getAccessibilityServiceInfo());
         if (isWarningRequired) {
             showPopupDialog(DialogEnums.ENABLE_WARNING_FROM_SHORTCUT);
         } else {
@@ -537,17 +524,6 @@
         mWarningDialog.dismiss();
     }
 
-    void onDialogButtonFromShortcutClicked(View view) {
-        final int viewId = view.getId();
-        if (viewId == R.id.permission_enable_allow_button) {
-            onAllowButtonFromShortcutClicked();
-        } else if (viewId == R.id.permission_enable_deny_button) {
-            onDenyButtonFromShortcutClicked();
-        } else {
-            throw new IllegalArgumentException("Unexpected view id");
-        }
-    }
-
     private void onAllowButtonFromShortcutClicked() {
         mIsDialogShown.set(false);
         if (Flags.editShortcutsInFullScreen()) {
@@ -576,13 +552,9 @@
             mToggleServiceSwitchPreference.setChecked(false);
             getArguments().putBoolean(AccessibilitySettings.EXTRA_CHECKED,
                     /* disableService */ false);
-            final boolean isWarningRequired;
-            if (android.view.accessibility.Flags.cleanupAccessibilityWarningDialog()) {
-                isWarningRequired = getPrefContext().getSystemService(AccessibilityManager.class)
-                        .isAccessibilityServiceWarningRequired(getAccessibilityServiceInfo());
-            } else {
-                isWarningRequired = !mShortcutPreference.isChecked();
-            }
+            final boolean isWarningRequired =
+                    getPrefContext().getSystemService(AccessibilityManager.class)
+                            .isAccessibilityServiceWarningRequired(getAccessibilityServiceInfo());
             if (isWarningRequired) {
                 showPopupDialog(DialogEnums.ENABLE_WARNING_FROM_TOGGLE);
             } else {
diff --git a/src/com/android/settings/privatespace/HidePrivateSpaceSummaryController.java b/src/com/android/settings/privatespace/HidePrivateSpaceSummaryController.java
index a366b70..f5100a7 100644
--- a/src/com/android/settings/privatespace/HidePrivateSpaceSummaryController.java
+++ b/src/com/android/settings/privatespace/HidePrivateSpaceSummaryController.java
@@ -49,8 +49,8 @@
 
     @Override
     public CharSequence getSummary() {
-        return isHidden() ? mContext.getString(R.string.privatespace_hide_on_summary)
-                : mContext.getString(R.string.privatespace_hide_off_summary);
+        return isHidden() ? mContext.getString(R.string.private_space_hide_on_summary)
+                : mContext.getString(R.string.private_space_hide_off_summary);
     }
 
     private boolean isHidden() {
diff --git a/src/com/android/settings/privatespace/onelock/UseOneLockControllerSwitch.java b/src/com/android/settings/privatespace/onelock/UseOneLockControllerSwitch.java
index 680f5c7..dfac100 100644
--- a/src/com/android/settings/privatespace/onelock/UseOneLockControllerSwitch.java
+++ b/src/com/android/settings/privatespace/onelock/UseOneLockControllerSwitch.java
@@ -192,7 +192,8 @@
             return;
         }
         new AlertDialog.Builder(mContext)
-                  .setMessage(R.string.private_space_new_lock_title)
+                  .setTitle(R.string.private_space_new_lock_title)
+                  .setMessage(R.string.private_space_new_lock_message)
                   .setPositiveButton(
                             R.string.private_space_set_lock_label,
                             (dialog, which) -> {
diff --git a/tests/robotests/src/com/android/settings/accessibility/ToggleAccessibilityServicePreferenceFragmentTest.java b/tests/robotests/src/com/android/settings/accessibility/ToggleAccessibilityServicePreferenceFragmentTest.java
index ae4f9a0..9be03e8 100644
--- a/tests/robotests/src/com/android/settings/accessibility/ToggleAccessibilityServicePreferenceFragmentTest.java
+++ b/tests/robotests/src/com/android/settings/accessibility/ToggleAccessibilityServicePreferenceFragmentTest.java
@@ -237,7 +237,6 @@
     }
 
     @Test
-    @EnableFlags(Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG)
     public void enableService_warningRequired_showWarning() throws Throwable {
         setupServiceWarningRequired(true);
         mFragment.mToggleServiceSwitchPreference =
@@ -250,7 +249,6 @@
     }
 
     @Test
-    @EnableFlags(Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG)
     public void enableService_warningNotRequired_dontShowWarning() throws Throwable {
         final AccessibilityServiceInfo info = setupServiceWarningRequired(false);
         mFragment.mToggleServiceSwitchPreference =
@@ -264,7 +262,6 @@
     }
 
     @Test
-    @EnableFlags(Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG)
     public void toggleShortcutPreference_warningRequired_showWarning() throws Throwable {
         setupServiceWarningRequired(true);
         mFragment.mShortcutPreference = new ShortcutPreference(mContext, /* attrs= */null);
@@ -278,7 +275,6 @@
     }
 
     @Test
-    @EnableFlags(Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG)
     public void toggleShortcutPreference_warningNotRequired_dontShowWarning() throws Throwable {
         setupServiceWarningRequired(false);
         mFragment.mShortcutPreference = new ShortcutPreference(mContext, /* attrs= */null);
@@ -292,7 +288,6 @@
     }
 
     @Test
-    @EnableFlags(Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG)
     public void clickShortcutSettingsPreference_warningRequired_showWarning() throws Throwable {
         setupServiceWarningRequired(true);
         mFragment.mShortcutPreference = new ShortcutPreference(mContext, /* attrs= */null);
@@ -304,7 +299,6 @@
     }
 
     @Test
-    @EnableFlags(Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG)
     @DisableFlags(
             com.android.settings.accessibility.Flags.FLAG_EDIT_SHORTCUTS_IN_FULL_SCREEN)
     public void clickShortcutSettingsPreference_warningNotRequired_dontShowWarning_showDialog()
@@ -319,8 +313,7 @@
     }
 
     @Test
-    @EnableFlags({Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG,
-            com.android.settings.accessibility.Flags.FLAG_EDIT_SHORTCUTS_IN_FULL_SCREEN})
+    @EnableFlags(com.android.settings.accessibility.Flags.FLAG_EDIT_SHORTCUTS_IN_FULL_SCREEN)
     public void clickShortcutSettingsPreference_warningNotRequired_dontShowWarning_launchActivity()
             throws Throwable {
         setupServiceWarningRequired(false);
@@ -365,7 +358,7 @@
     }
 
     @Test
-    @EnableFlags({Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG, Flags.FLAG_A11Y_QS_SHORTCUT})
+    @EnableFlags(Flags.FLAG_A11Y_QS_SHORTCUT)
     public void toggleShortcutPreference_noUserPreferredShortcut_hasQsTile_enableQsShortcut()
             throws Throwable {
         PreferredShortcuts.clearPreferredShortcuts(mContext);
@@ -383,7 +376,7 @@
     }
 
     @Test
-    @EnableFlags({Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG, Flags.FLAG_A11Y_QS_SHORTCUT})
+    @EnableFlags(Flags.FLAG_A11Y_QS_SHORTCUT)
     public void toggleShortcutPreference_noUserPreferredShortcut_noQsTile_enableSoftwareShortcut()
             throws Throwable {
         PreferredShortcuts.clearPreferredShortcuts(mContext);
@@ -401,7 +394,6 @@
     }
 
     @Test
-    @EnableFlags(Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG)
     @DisableFlags(Flags.FLAG_A11Y_QS_SHORTCUT)
     public void toggleShortcutPreference_noUserPreferredShortcut_hasQsTile_flagOff_enableSoftwareShortcut()
             throws Throwable {
@@ -420,7 +412,6 @@
     }
 
     @Test
-    @EnableFlags(Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG)
     @DisableFlags(Flags.FLAG_A11Y_QS_SHORTCUT)
     public void toggleShortcutPreference_noUserPreferredShortcut_noQsTile_flagOff_enableSoftwareShortcut()
             throws Throwable {
@@ -439,7 +430,7 @@
     }
 
     @Test
-    @EnableFlags({Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG, Flags.FLAG_A11Y_QS_SHORTCUT})
+    @EnableFlags(Flags.FLAG_A11Y_QS_SHORTCUT)
     public void toggleShortcutPreference_userPreferVolumeKeysShortcut_noQsTile_enableVolumeKeysShortcut()
             throws Throwable {
         setupServiceWarningRequired(false);
@@ -462,7 +453,7 @@
     }
 
     @Test
-    @EnableFlags({Flags.FLAG_CLEANUP_ACCESSIBILITY_WARNING_DIALOG, Flags.FLAG_A11Y_QS_SHORTCUT})
+    @EnableFlags(Flags.FLAG_A11Y_QS_SHORTCUT)
     public void toggleShortcutPreference_userPreferVolumeKeysShortcut_hasQsTile_enableVolumeKeysShortcut()
             throws Throwable {
         setupServiceWarningRequired(false);
