Merge "Remove ranking code for Old Search"
diff --git a/res/values/strings.xml b/res/values/strings.xml
index b7a8726..bff3170 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -2961,7 +2961,7 @@
     <!-- Tethering controls, item title to go into the tethering settings when USB and Bluetooth tethering are available [CHAR LIMIT=25]-->
     <string name="tether_settings_title_usb_bluetooth">Tethering</string>
     <!-- Tethering controls, item title to go into the tethering settings when USB, Bluetooth and Wifi tethering are available [CHAR LIMIT=50]-->
-    <string name="tether_settings_title_all">Hotspot &amp; Tethering</string>
+    <string name="tether_settings_title_all">Hotspot &amp; tethering</string>
     <!-- Tethering setting summary when both Wi-Fi hotspot and tether are turned on [CHAR LIMIT=NONE]-->
     <string name="tether_settings_summary_hotspot_on_tether_on">Hotspot on, tethering</string>
     <!-- Tethering setting summary when Wi-Fi hotspot is on and tether is off [CHAR LIMIT=NONE]-->
@@ -3019,7 +3019,7 @@
     <string name="tethering_help_button_text">Help</string>
 
     <!-- Wireless controls, item title to go into the network settings -->
-    <string name="network_settings_title">Mobile networks</string>
+    <string name="network_settings_title">Mobile network</string>
 
     <!-- Mobile plan [CHAR LIMIT=35]-->
     <string name="manage_mobile_plan_title" translatable="true">Mobile plan</string>
@@ -5478,6 +5478,8 @@
     <string name="vpn_no_network">There is no network connection. Please try again later.</string>
     <!-- Toast message when VPN has disconnected automatically due to Clear credentials. [CHAR LIMIT=NONE] -->
     <string name="vpn_disconnected">Disconnected from VPN</string>
+    <!-- Seting subtext indicating the device is not currently connected to any VPN [CHAR LIMIT=40]-->
+    <string name="vpn_disconnected_summary">None</string>
     <!-- Toast message when a certificate is missing. [CHAR LIMIT=100] -->
     <string name="vpn_missing_cert">A certificate is missing. Please edit the profile.</string>
 
@@ -7192,7 +7194,7 @@
     <!-- Title of one of the choices in a dialog (with title defined in usb_use) that lets the user
          select what the USB connection for this device should be used for. This choice
          is for transferring files via MTP. -->
-    <string name="usb_use_file_transfers">Transfer files</string>
+    <string name="usb_use_file_transfers">Transferring files</string>
     <!-- Description of one of the choices in a dialog (with title defined in usb_use) that lets the user
          select what the USB connection for this device should be used for. This choice
          is for transferring files via MTP. -->
@@ -7200,7 +7202,7 @@
     <!-- Title of one of the choices in a dialog (with title defined in usb_use) that lets the user
          select what the USB connection for this device should be used for. This choice
          is for transferring photos via PTP. -->
-    <string name="usb_use_photo_transfers">Transfer photos (PTP)</string>
+    <string name="usb_use_photo_transfers">Transferring photos (PTP)</string>
     <!-- Description of one of the choices in a dialog (with title defined in usb_use) that lets the user
          select what the USB connection for this device should be used for. This choice
          is for transferring photos via PTP. -->
@@ -7208,7 +7210,7 @@
     <!-- Title of one of the choices in a dialog (with title defined in usb_use) that lets the user
          select what the USB connection for this device should be used for. This choice
          is for entering MIDI mode. -->
-    <string name="usb_use_MIDI">Use device as MIDI</string>
+    <string name="usb_use_MIDI">Using device as MIDI</string>
     <!-- Description of one of the choices in a dialog (with title defined in usb_use) that lets the user
          select what the USB connection for this device should be used for. This choice
          is for entering MIDI mode. -->
@@ -7220,8 +7222,6 @@
 
     <!-- Settings item title for USB preference [CHAR LIMIT=35] -->
     <string name="usb_pref">USB</string>
-    <!-- Summary for the USB preference when nothing is connected through the usb port.  [CHAR LIMIT=40] -->
-    <string name="usb_nothing_connected">Nothing connected</string>
 
     <!-- Settings item title for background check prefs [CHAR LIMIT=35] -->
     <string name="background_check_pref">Background check</string>
@@ -7346,38 +7346,38 @@
     <string name="accessibility_lock_screen_progress"><xliff:g id="count" example="1">%1$d</xliff:g> of <xliff:g id="count" example="1">%2$d</xliff:g> characters used</string>
 
     <!-- System Alert Window settings -->
-    <!-- Title of Draw Overlay preference item [CHAR LIMIT=55] -->
-    <string name="draw_overlay_title">Apps that can draw over other apps</string>
-    <!-- Title of draw overlay screen [CHAR LIMIT=30] -->
-    <string name="draw_overlay">Draw over other apps</string>
+    <!-- Title of display overlay preference item [CHAR LIMIT=55] -->
+    <string name="draw_overlay_title">Apps that can display over other apps</string>
+    <!-- Title of display overlay screen [CHAR LIMIT=30] -->
+    <string name="draw_overlay">Display over other apps</string>
     <!-- Settings title in main settings screen for SYSTEM_ALERT_WINDOW [CHAR LIMIT=45] -->
-    <string name="system_alert_window_settings">Draw over other apps</string>
+    <string name="system_alert_window_settings">Display over other apps</string>
     <!-- Title for the apps with SYSTEM_ALERT_WINDOW permission/privilege [CHAR LIMIT=20] -->
     <string name="system_alert_window_apps_title">Apps</string>
-    <!-- Title for the apps that are allowed to draw on top of other apps [CHAR LIMIT=60] -->
-    <string name="system_alert_window_access_title">Draw over other apps</string>
-    <!-- Label for setting which controls whether app can draw overlays [CHAR LIMIT=45] -->
-    <string name="permit_draw_overlay">Permit drawing over other apps</string>
+    <!-- Title for the apps that are allowed to display over other apps [CHAR LIMIT=60] -->
+    <string name="system_alert_window_access_title">Display over other apps</string>
+    <!-- Label for setting which controls whether app can display over other apps [CHAR LIMIT=45] -->
+    <string name="permit_draw_overlay">Allow display over other apps</string>
     <!-- Link to the apps page for SYSTEM_ALERT_WINDOW settings [CHAR LIMIT=45] -->
-    <string name="app_overlay_permission_preference">App draw on top permission</string>
+    <string name="app_overlay_permission_preference">App display on top permission</string>
     <!-- Description of allowing overlay setting [CHAR LIMIT=NONE] -->
-    <string name="allow_overlay_description">This permission allows an app to display on top of other apps you\u2019re using and may interfere with your use of the interface in other applications, or change what you think you are seeing in other applications.</string>
+    <string name="allow_overlay_description">This feature allows an app to display on top of other apps you\u2019re using. It may interfere with your use of those apps or change the way they seem to appear or behave.</string>
 
     <!-- Keyword for VR setting -->
     <string name="keywords_vr_listener">vr virtual reality listener stereo helper service</string>
     <!-- Keyword for SYSTEM_ALERT_WINDOW -->
-    <string name="keywords_system_alert_window">system alert window dialog draw on top other apps</string>
+    <string name="keywords_system_alert_window">system alert window dialog display on top other apps</string>
     <!-- Main settings screen item's title to go into the overlay settings screen [CHAR LIMIT=30] -->
-    <string name="overlay_settings">Draw over other apps</string>
+    <string name="overlay_settings">Display over other apps</string>
 
-    <!-- Summary of number of apps currently can draw overlays [CHAR LIMIT=60] -->
-    <string name="system_alert_window_summary"><xliff:g id="count" example="10">%1$d</xliff:g> of <xliff:g id="count" example="10">%2$d</xliff:g> apps allowed to draw on top of other apps</string>
+    <!-- Summary of number of apps currently can display over other apps [CHAR LIMIT=60] -->
+    <string name="system_alert_window_summary"><xliff:g id="count" example="10">%1$d</xliff:g> of <xliff:g id="count" example="10">%2$d</xliff:g> apps allowed to display over other apps</string>
 
-    <!-- Label for showing apps that can draw overlays [CHAR LIMIT=45] -->
+    <!-- Label for showing apps that can display over other apps [CHAR LIMIT=45] -->
     <string name="filter_overlay_apps">Apps with permission</string>
-    <!-- Summary of app allowed to draw overlay [CHAR LIMIT=60] -->
+    <!-- Summary of app allowed to display over other apps [CHAR LIMIT=60] -->
     <string name="system_alert_window_on">Yes</string>
-    <!-- Summary of app not allowed to draw overlay [CHAR LIMIT=60] -->
+    <!-- Summary of app not allowed to display over other apps [CHAR LIMIT=60] -->
     <string name="system_alert_window_off">No</string>
 
     <!-- Title for settings screen for controlling apps that can install other apps on device [CHAR LIMIT=50] -->
@@ -7390,7 +7390,7 @@
     <string name="write_settings">Modify system settings</string>
     <!-- Keyword for WRITE_SETTINGS -->
     <string name="keywords_write_settings">write modify system settings</string>
-    <!-- Summary of number of apps currently can draw overlays [CHAR LIMIT=60] -->
+    <!-- Summary of number of apps currently can write system settings [CHAR LIMIT=60] -->
     <string name="write_settings_summary"><xliff:g id="count" example="10">%1$d</xliff:g> of <xliff:g id="count" example="10">%2$d</xliff:g> apps allowed to modify system settings</string>
 
     <!-- Label for showing apps that can install other apps [CHAR LIMIT=45] -->
@@ -7467,7 +7467,7 @@
     <string name="screen_zoom_conversation_timestamp_4">Tue 6:03PM</string>
 
     <!-- Wi-Fi state - Disconnected [CHAR LIMIT=NONE] -->
-    <string name="disconnected">Disconnected</string>
+    <string name="disconnected">Not connected</string>
 
     <!-- Summary of data usage [CHAR LIMIT=NONE] -->
     <string name="data_usage_summary_format"><xliff:g id="amount" example="50%">%1$s</xliff:g> of data used</string>
@@ -7880,8 +7880,8 @@
     <!-- Title of screen controlling which apps have access to send premium SMS messages [CHAR LIMIT=60] -->
     <string name="premium_sms_access">Premium SMS access</string>
 
-    <!-- [CHAR LIMIT=25] Bluetooth is disabled. -->
-    <string name="bluetooth_disabled">Disabled</string>
+    <!-- Bluetooth is disabled. -->
+    <string name="bluetooth_disabled">Not visible to other devices</string>
 
     <!-- [CHAR LIMIT=60] Name of dev option called "System UI demo mode" -->
     <string name="demo_mode">System UI demo mode</string>
diff --git a/res/xml/ia_display_settings.xml b/res/xml/display_settings.xml
similarity index 100%
rename from res/xml/ia_display_settings.xml
rename to res/xml/display_settings.xml
diff --git a/res/xml/ia_sound_settings.xml b/res/xml/sound_settings.xml
similarity index 100%
rename from res/xml/ia_sound_settings.xml
rename to res/xml/sound_settings.xml
diff --git a/src/com/android/settings/DisplaySettings.java b/src/com/android/settings/DisplaySettings.java
index 6fbffe8..dd4c9a4 100644
--- a/src/com/android/settings/DisplaySettings.java
+++ b/src/com/android/settings/DisplaySettings.java
@@ -36,7 +36,6 @@
 import com.android.settings.display.TimeoutPreferenceController;
 import com.android.settings.display.VrDisplayPreferenceController;
 import com.android.settings.display.WallpaperPreferenceController;
-import com.android.settings.overlay.FeatureFactory;
 import com.android.settings.search.BaseSearchIndexProvider;
 import com.android.settings.search.Indexable;
 
@@ -64,7 +63,7 @@
 
     @Override
     protected int getPreferenceScreenResId() {
-        return R.xml.ia_display_settings;
+        return R.xml.display_settings;
     }
 
     @Override
@@ -104,7 +103,7 @@
                     final ArrayList<SearchIndexableResource> result = new ArrayList<>();
 
                     final SearchIndexableResource sir = new SearchIndexableResource(context);
-                    sir.xmlResId = R.xml.ia_display_settings;
+                    sir.xmlResId = R.xml.display_settings;
                     result.add(sir);
                     return result;
                 }
diff --git a/src/com/android/settings/connecteddevice/UsbModePreferenceController.java b/src/com/android/settings/connecteddevice/UsbModePreferenceController.java
index 5f700bd..6c1a28b 100644
--- a/src/com/android/settings/connecteddevice/UsbModePreferenceController.java
+++ b/src/com/android/settings/connecteddevice/UsbModePreferenceController.java
@@ -119,7 +119,7 @@
                 preference.setEnabled(true);
                 preference.setSummary(getTitle(mode));
             } else {
-                preference.setSummary(R.string.usb_nothing_connected);
+                preference.setSummary(R.string.disconnected);
                 preference.setEnabled(false);
             }
         }
diff --git a/src/com/android/settings/network/VpnPreferenceController.java b/src/com/android/settings/network/VpnPreferenceController.java
index 86ff175..72b361a 100644
--- a/src/com/android/settings/network/VpnPreferenceController.java
+++ b/src/com/android/settings/network/VpnPreferenceController.java
@@ -150,13 +150,13 @@
             uid = userInfo.id;
         }
         VpnConfig vpn = vpns.get(uid);
-        final String vpnName;
+        final String summary;
         if (vpn == null) {
-            vpnName = null;
+            summary = mContext.getString(R.string.vpn_disconnected_summary);
         } else {
-            vpnName = getNameForVpnConfig(vpn, UserHandle.of(uid));
+            summary = getNameForVpnConfig(vpn, UserHandle.of(uid));
         }
-        new Handler(Looper.getMainLooper()).post(() -> mPreference.setSummary(vpnName));
+        new Handler(Looper.getMainLooper()).post(() -> mPreference.setSummary(summary));
     }
 
     private String getNameForVpnConfig(VpnConfig cfg, UserHandle user) {
diff --git a/src/com/android/settings/notification/SoundSettings.java b/src/com/android/settings/notification/SoundSettings.java
index df60573..79a8970 100644
--- a/src/com/android/settings/notification/SoundSettings.java
+++ b/src/com/android/settings/notification/SoundSettings.java
@@ -98,7 +98,7 @@
 
     @Override
     protected int getPreferenceScreenResId() {
-        return R.xml.ia_sound_settings;
+        return R.xml.sound_settings;
     }
 
     @Override
@@ -216,7 +216,7 @@
                 public List<SearchIndexableResource> getXmlResourcesToIndex(
                         Context context, boolean enabled) {
                     final SearchIndexableResource sir = new SearchIndexableResource(context);
-                    sir.xmlResId = R.xml.ia_sound_settings;
+                    sir.xmlResId = R.xml.sound_settings;
                     return Arrays.asList(sir);
                 }
 
diff --git a/src/com/android/settings/notification/WorkSoundPreferenceController.java b/src/com/android/settings/notification/WorkSoundPreferenceController.java
index a4d7b8d..a80f503 100644
--- a/src/com/android/settings/notification/WorkSoundPreferenceController.java
+++ b/src/com/android/settings/notification/WorkSoundPreferenceController.java
@@ -222,7 +222,7 @@
                     KEY_WORK_ALARM_RINGTONE);
         }
         if (!mVoiceCapable) {
-            mWorkPreferenceCategory.removePreference(mWorkPhoneRingtonePreference);
+            mWorkPhoneRingtonePreference.setVisible(false);
             mWorkPhoneRingtonePreference = null;
         }
 
diff --git a/src/com/android/settings/sim/SimDialogActivity.java b/src/com/android/settings/sim/SimDialogActivity.java
index dccba13..853f80d 100644
--- a/src/com/android/settings/sim/SimDialogActivity.java
+++ b/src/com/android/settings/sim/SimDialogActivity.java
@@ -59,8 +59,7 @@
     @Override
     protected void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);
-        final Bundle extras = getIntent().getExtras();
-        final int dialogType = extras.getInt(DIALOG_TYPE_KEY, INVALID_PICK);
+        final int dialogType = getIntent().getIntExtra(DIALOG_TYPE_KEY, INVALID_PICK);
 
         switch (dialogType) {
             case DATA_PICK:
@@ -69,7 +68,7 @@
                 createDialog(this, dialogType).show();
                 break;
             case PREFERRED_PICK:
-                displayPreferredDialog(extras.getInt(PREFERRED_SIM));
+                displayPreferredDialog(getIntent().getIntExtra(PREFERRED_SIM, 0));
                 break;
             default:
                 throw new IllegalArgumentException("Invalid dialog type " + dialogType + " sent.");
diff --git a/src/com/android/settings/widget/ExploreByTouchHelper.java b/src/com/android/settings/widget/ExploreByTouchHelper.java
deleted file mode 100644
index b64a74c..0000000
--- a/src/com/android/settings/widget/ExploreByTouchHelper.java
+++ /dev/null
@@ -1,724 +0,0 @@
-/*
- * Copyright (C) 2013 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.widget;
-
-import android.content.Context;
-import android.graphics.Rect;
-import android.os.Bundle;
-import android.view.MotionEvent;
-import android.view.View;
-import android.view.ViewParent;
-import android.view.accessibility.AccessibilityEvent;
-import android.view.accessibility.AccessibilityManager;
-import android.view.accessibility.AccessibilityNodeInfo;
-import android.view.accessibility.AccessibilityNodeProvider;
-
-import java.util.LinkedList;
-import java.util.List;
-
-/**
- * Copied from setup wizard, which is in turn a modified copy of
- * com.android.internal.ExploreByTouchHelper with the following modifications:
- *
- * - Make accessibility calls to the views, instead of to the accessibility delegate directly to
- *   make sure those methods for View subclasses are called.
- *
- * ExploreByTouchHelper is a utility class for implementing accessibility
- * support in custom {@link android.view.View}s that represent a collection of View-like
- * logical items. It extends {@link android.view.accessibility.AccessibilityNodeProvider} and
- * simplifies many aspects of providing information to accessibility services
- * and managing accessibility focus. This class does not currently support
- * hierarchies of logical items.
- * <p>
- * This should be applied to the parent view using
- * {@link android.view.View#setAccessibilityDelegate}:
- *
- * <pre>
- * mAccessHelper = ExploreByTouchHelper.create(someView, mAccessHelperCallback);
- * ViewCompat.setAccessibilityDelegate(someView, mAccessHelper);
- * </pre>
- */
-public abstract class ExploreByTouchHelper extends View.AccessibilityDelegate {
-    /** Virtual node identifier value for invalid nodes. */
-    public static final int INVALID_ID = Integer.MIN_VALUE;
-
-    /** Default class name used for virtual views. */
-    private static final String DEFAULT_CLASS_NAME = View.class.getName();
-
-    // Temporary, reusable data structures.
-    private final Rect mTempScreenRect = new Rect();
-    private final Rect mTempParentRect = new Rect();
-    private final Rect mTempVisibleRect = new Rect();
-    private final int[] mTempGlobalRect = new int[2];
-
-    /** View's context **/
-    private Context mContext;
-
-    /** System accessibility manager, used to check state and send events. */
-    private final AccessibilityManager mManager;
-
-    /** View whose internal structure is exposed through this helper. */
-    private final View mView;
-
-    /** Node provider that handles creating nodes and performing actions. */
-    private ExploreByTouchNodeProvider mNodeProvider;
-
-    /** Virtual view id for the currently focused logical item. */
-    private int mFocusedVirtualViewId = INVALID_ID;
-
-    /** Virtual view id for the currently hovered logical item. */
-    private int mHoveredVirtualViewId = INVALID_ID;
-
-    /**
-     * Factory method to create a new {@link com.google.android.setupwizard.util.ExploreByTouchHelper}.
-     *
-     * @param forView View whose logical children are exposed by this helper.
-     */
-    public ExploreByTouchHelper(View forView) {
-        if (forView == null) {
-            throw new IllegalArgumentException("View may not be null");
-        }
-
-        mView = forView;
-        mContext = forView.getContext();
-        mManager = (AccessibilityManager) mContext.getSystemService(Context.ACCESSIBILITY_SERVICE);
-    }
-
-    /**
-     * Returns the {@link android.view.accessibility.AccessibilityNodeProvider} for this helper.
-     *
-     * @param host View whose logical children are exposed by this helper.
-     * @return The accessibility node provider for this helper.
-     */
-    @Override
-    public AccessibilityNodeProvider getAccessibilityNodeProvider(View host) {
-        if (mNodeProvider == null) {
-            mNodeProvider = new ExploreByTouchNodeProvider();
-        }
-        return mNodeProvider;
-    }
-
-    /**
-     * Dispatches hover {@link android.view.MotionEvent}s to the virtual view hierarchy when
-     * the Explore by Touch feature is enabled.
-     * <p>
-     * This method should be called by overriding
-     * {@link android.view.View#dispatchHoverEvent}:
-     *
-     * <pre>&#64;Override
-     * public boolean dispatchHoverEvent(MotionEvent event) {
-     *   if (mHelper.dispatchHoverEvent(this, event) {
-     *     return true;
-     *   }
-     *   return super.dispatchHoverEvent(event);
-     * }
-     * </pre>
-     *
-     * @param event The hover event to dispatch to the virtual view hierarchy.
-     * @return Whether the hover event was handled.
-     */
-    public boolean dispatchHoverEvent(MotionEvent event) {
-        if (!mManager.isEnabled() || !mManager.isTouchExplorationEnabled()) {
-            return false;
-        }
-
-        switch (event.getAction()) {
-            case MotionEvent.ACTION_HOVER_MOVE:
-            case MotionEvent.ACTION_HOVER_ENTER:
-                final int virtualViewId = getVirtualViewAt(event.getX(), event.getY());
-                updateHoveredVirtualView(virtualViewId);
-                return (virtualViewId != INVALID_ID);
-            case MotionEvent.ACTION_HOVER_EXIT:
-                if (mFocusedVirtualViewId != INVALID_ID) {
-                    updateHoveredVirtualView(INVALID_ID);
-                    return true;
-                }
-                return false;
-            default:
-                return false;
-        }
-    }
-
-    /**
-     * Populates an event of the specified type with information about an item
-     * and attempts to send it up through the view hierarchy.
-     * <p>
-     * You should call this method after performing a user action that normally
-     * fires an accessibility event, such as clicking on an item.
-     *
-     * <pre>public void performItemClick(T item) {
-     *   ...
-     *   sendEventForVirtualViewId(item.id, AccessibilityEvent.TYPE_VIEW_CLICKED);
-     * }
-     * </pre>
-     *
-     * @param virtualViewId The virtual view id for which to send an event.
-     * @param eventType The type of event to send.
-     * @return true if the event was sent successfully.
-     */
-    public boolean sendEventForVirtualView(int virtualViewId, int eventType) {
-        if ((virtualViewId == INVALID_ID) || !mManager.isEnabled()) {
-            return false;
-        }
-
-        final ViewParent parent = mView.getParent();
-        if (parent == null) {
-            return false;
-        }
-
-        final AccessibilityEvent event = createEvent(virtualViewId, eventType);
-        return parent.requestSendAccessibilityEvent(mView, event);
-    }
-
-    /**
-     * Notifies the accessibility framework that the properties of the parent
-     * view have changed.
-     * <p>
-     * You <b>must</b> call this method after adding or removing items from the
-     * parent view.
-     */
-    public void invalidateRoot() {
-        invalidateVirtualView(View.NO_ID);
-    }
-
-    /**
-     * Notifies the accessibility framework that the properties of a particular
-     * item have changed.
-     * <p>
-     * You <b>must</b> call this method after changing any of the properties set
-     * in {@link #onPopulateNodeForVirtualView}.
-     *
-     * @param virtualViewId The virtual view id to invalidate.
-     */
-    public void invalidateVirtualView(int virtualViewId) {
-        sendEventForVirtualView(virtualViewId, AccessibilityEvent.TYPE_WINDOW_CONTENT_CHANGED);
-    }
-
-    /**
-     * Returns the virtual view id for the currently focused item,
-     *
-     * @return A virtual view id, or {@link #INVALID_ID} if no item is
-     *         currently focused.
-     */
-    public int getFocusedVirtualView() {
-        return mFocusedVirtualViewId;
-    }
-
-    /**
-     * Sets the currently hovered item, sending hover accessibility events as
-     * necessary to maintain the correct state.
-     *
-     * @param virtualViewId The virtual view id for the item currently being
-     *            hovered, or {@link #INVALID_ID} if no item is hovered within
-     *            the parent view.
-     */
-    private void updateHoveredVirtualView(int virtualViewId) {
-        if (mHoveredVirtualViewId == virtualViewId) {
-            return;
-        }
-
-        final int previousVirtualViewId = mHoveredVirtualViewId;
-        mHoveredVirtualViewId = virtualViewId;
-
-        // Stay consistent with framework behavior by sending ENTER/EXIT pairs
-        // in reverse order. This is accurate as of API 18.
-        sendEventForVirtualView(virtualViewId, AccessibilityEvent.TYPE_VIEW_HOVER_ENTER);
-        sendEventForVirtualView(previousVirtualViewId, AccessibilityEvent.TYPE_VIEW_HOVER_EXIT);
-    }
-
-    /**
-     * Constructs and returns an {@link android.view.accessibility.AccessibilityEvent} for the specified
-     * virtual view id, which includes the host view ({@link android.view.View#NO_ID}).
-     *
-     * @param virtualViewId The virtual view id for the item for which to
-     *            construct an event.
-     * @param eventType The type of event to construct.
-     * @return An {@link android.view.accessibility.AccessibilityEvent} populated with information about
-     *         the specified item.
-     */
-    private AccessibilityEvent createEvent(int virtualViewId, int eventType) {
-        switch (virtualViewId) {
-            case View.NO_ID:
-                return createEventForHost(eventType);
-            default:
-                return createEventForChild(virtualViewId, eventType);
-        }
-    }
-
-    /**
-     * Constructs and returns an {@link android.view.accessibility.AccessibilityEvent} for the host node.
-     *
-     * @param eventType The type of event to construct.
-     * @return An {@link android.view.accessibility.AccessibilityEvent} populated with information about
-     *         the specified item.
-     */
-    private AccessibilityEvent createEventForHost(int eventType) {
-        final AccessibilityEvent event = AccessibilityEvent.obtain(eventType);
-        mView.onInitializeAccessibilityEvent(event);
-        return event;
-    }
-
-    /**
-     * Constructs and returns an {@link android.view.accessibility.AccessibilityEvent} populated with
-     * information about the specified item.
-     *
-     * @param virtualViewId The virtual view id for the item for which to
-     *            construct an event.
-     * @param eventType The type of event to construct.
-     * @return An {@link android.view.accessibility.AccessibilityEvent} populated with information about
-     *         the specified item.
-     */
-    private AccessibilityEvent createEventForChild(int virtualViewId, int eventType) {
-        final AccessibilityEvent event = AccessibilityEvent.obtain(eventType);
-        event.setEnabled(true);
-        event.setClassName(DEFAULT_CLASS_NAME);
-
-        // Allow the client to populate the event.
-        onPopulateEventForVirtualView(virtualViewId, event);
-
-        // Make sure the developer is following the rules.
-        if (event.getText().isEmpty() && (event.getContentDescription() == null)) {
-            throw new RuntimeException("Callbacks must add text or a content description in "
-                    + "populateEventForVirtualViewId()");
-        }
-
-        // Don't allow the client to override these properties.
-        event.setPackageName(mView.getContext().getPackageName());
-        event.setSource(mView, virtualViewId);
-
-        return event;
-    }
-
-    /**
-     * Constructs and returns an {@link android.view.accessibility.AccessibilityNodeInfo} for the
-     * specified virtual view id, which includes the host view
-     * ({@link android.view.View#NO_ID}).
-     *
-     * @param virtualViewId The virtual view id for the item for which to
-     *            construct a node.
-     * @return An {@link android.view.accessibility.AccessibilityNodeInfo} populated with information
-     *         about the specified item.
-     */
-    private AccessibilityNodeInfo createNode(int virtualViewId) {
-        switch (virtualViewId) {
-            case View.NO_ID:
-                return createNodeForHost();
-            default:
-                return createNodeForChild(virtualViewId);
-        }
-    }
-
-    /**
-     * Constructs and returns an {@link android.view.accessibility.AccessibilityNodeInfo} for the
-     * host view populated with its virtual descendants.
-     *
-     * @return An {@link android.view.accessibility.AccessibilityNodeInfo} for the parent node.
-     */
-    private AccessibilityNodeInfo createNodeForHost() {
-        final AccessibilityNodeInfo node = AccessibilityNodeInfo.obtain(mView);
-        mView.onInitializeAccessibilityNodeInfo(node);
-
-        // Add the virtual descendants.
-        final LinkedList<Integer> virtualViewIds = new LinkedList<Integer>();
-        getVisibleVirtualViews(virtualViewIds);
-
-        for (Integer childVirtualViewId : virtualViewIds) {
-            node.addChild(mView, childVirtualViewId);
-        }
-
-        return node;
-    }
-
-    /**
-     * Constructs and returns an {@link android.view.accessibility.AccessibilityNodeInfo} for the
-     * specified item. Automatically manages accessibility focus actions.
-     * <p>
-     * Allows the implementing class to specify most node properties, but
-     * overrides the following:
-     * <ul>
-     * <li>{@link android.view.accessibility.AccessibilityNodeInfo#setPackageName}
-     * <li>{@link android.view.accessibility.AccessibilityNodeInfo#setClassName}
-     * <li>{@link android.view.accessibility.AccessibilityNodeInfo#setParent(android.view.View)}
-     * <li>{@link android.view.accessibility.AccessibilityNodeInfo#setSource(android.view.View, int)}
-     * <li>{@link android.view.accessibility.AccessibilityNodeInfo#setVisibleToUser}
-     * <li>{@link android.view.accessibility.AccessibilityNodeInfo#setBoundsInScreen(android.graphics.Rect)}
-     * </ul>
-     * <p>
-     * Uses the bounds of the parent view and the parent-relative bounding
-     * rectangle specified by
-     * {@link android.view.accessibility.AccessibilityNodeInfo#getBoundsInParent} to automatically
-     * update the following properties:
-     * <ul>
-     * <li>{@link android.view.accessibility.AccessibilityNodeInfo#setVisibleToUser}
-     * <li>{@link android.view.accessibility.AccessibilityNodeInfo#setBoundsInParent}
-     * </ul>
-     *
-     * @param virtualViewId The virtual view id for item for which to construct
-     *            a node.
-     * @return An {@link android.view.accessibility.AccessibilityNodeInfo} for the specified item.
-     */
-    private AccessibilityNodeInfo createNodeForChild(int virtualViewId) {
-        final AccessibilityNodeInfo node = AccessibilityNodeInfo.obtain();
-
-        // Ensure the client has good defaults.
-        node.setEnabled(true);
-        node.setClassName(DEFAULT_CLASS_NAME);
-
-        // Allow the client to populate the node.
-        onPopulateNodeForVirtualView(virtualViewId, node);
-
-        // Make sure the developer is following the rules.
-        if ((node.getText() == null) && (node.getContentDescription() == null)) {
-            throw new RuntimeException("Callbacks must add text or a content description in "
-                    + "populateNodeForVirtualViewId()");
-        }
-
-        node.getBoundsInParent(mTempParentRect);
-        if (mTempParentRect.isEmpty()) {
-            throw new RuntimeException("Callbacks must set parent bounds in "
-                    + "populateNodeForVirtualViewId()");
-        }
-
-        final int actions = node.getActions();
-        if ((actions & AccessibilityNodeInfo.ACTION_ACCESSIBILITY_FOCUS) != 0) {
-            throw new RuntimeException("Callbacks must not add ACTION_ACCESSIBILITY_FOCUS in "
-                    + "populateNodeForVirtualViewId()");
-        }
-        if ((actions & AccessibilityNodeInfo.ACTION_CLEAR_ACCESSIBILITY_FOCUS) != 0) {
-            throw new RuntimeException("Callbacks must not add ACTION_CLEAR_ACCESSIBILITY_FOCUS in "
-                    + "populateNodeForVirtualViewId()");
-        }
-
-        // Don't allow the client to override these properties.
-        node.setPackageName(mView.getContext().getPackageName());
-        node.setSource(mView, virtualViewId);
-        node.setParent(mView);
-
-        // Manage internal accessibility focus state.
-        if (mFocusedVirtualViewId == virtualViewId) {
-            node.setAccessibilityFocused(true);
-            node.addAction(AccessibilityNodeInfo.ACTION_CLEAR_ACCESSIBILITY_FOCUS);
-        } else {
-            node.setAccessibilityFocused(false);
-            node.addAction(AccessibilityNodeInfo.ACTION_ACCESSIBILITY_FOCUS);
-        }
-
-        // Set the visibility based on the parent bound.
-        if (intersectVisibleToUser(mTempParentRect)) {
-            node.setVisibleToUser(true);
-            node.setBoundsInParent(mTempParentRect);
-        }
-
-        // Calculate screen-relative bound.
-        mView.getLocationOnScreen(mTempGlobalRect);
-        final int offsetX = mTempGlobalRect[0];
-        final int offsetY = mTempGlobalRect[1];
-        mTempScreenRect.set(mTempParentRect);
-        mTempScreenRect.offset(offsetX, offsetY);
-        node.setBoundsInScreen(mTempScreenRect);
-
-        return node;
-    }
-
-    private boolean performAction(int virtualViewId, int action, Bundle arguments) {
-        switch (virtualViewId) {
-            case View.NO_ID:
-                return performActionForHost(action, arguments);
-            default:
-                return performActionForChild(virtualViewId, action, arguments);
-        }
-    }
-
-    private boolean performActionForHost(int action, Bundle arguments) {
-        return mView.performAccessibilityAction(action, arguments);
-    }
-
-    private boolean performActionForChild(int virtualViewId, int action, Bundle arguments) {
-        switch (action) {
-            case AccessibilityNodeInfo.ACTION_ACCESSIBILITY_FOCUS:
-            case AccessibilityNodeInfo.ACTION_CLEAR_ACCESSIBILITY_FOCUS:
-                return manageFocusForChild(virtualViewId, action, arguments);
-            default:
-                return onPerformActionForVirtualView(virtualViewId, action, arguments);
-        }
-    }
-
-    private boolean manageFocusForChild(int virtualViewId, int action, Bundle arguments) {
-        switch (action) {
-            case AccessibilityNodeInfo.ACTION_ACCESSIBILITY_FOCUS:
-                return requestAccessibilityFocus(virtualViewId);
-            case AccessibilityNodeInfo.ACTION_CLEAR_ACCESSIBILITY_FOCUS:
-                return clearAccessibilityFocus(virtualViewId);
-            default:
-                return false;
-        }
-    }
-
-    /**
-     * Computes whether the specified {@link android.graphics.Rect} intersects with the visible
-     * portion of its parent {@link android.view.View}. Modifies {@code localRect} to contain
-     * only the visible portion.
-     *
-     * @param localRect A rectangle in local (parent) coordinates.
-     * @return Whether the specified {@link android.graphics.Rect} is visible on the screen.
-     */
-    private boolean intersectVisibleToUser(Rect localRect) {
-        // Missing or empty bounds mean this view is not visible.
-        if ((localRect == null) || localRect.isEmpty()) {
-            return false;
-        }
-
-        // Attached to invisible window means this view is not visible.
-        if (mView.getWindowVisibility() != View.VISIBLE) {
-            return false;
-        }
-
-        // An invisible predecessor means that this view is not visible.
-        ViewParent viewParent = mView.getParent();
-        while (viewParent instanceof View) {
-            final View view = (View) viewParent;
-            if ((view.getAlpha() <= 0) || (view.getVisibility() != View.VISIBLE)) {
-                return false;
-            }
-            viewParent = view.getParent();
-        }
-
-        // A null parent implies the view is not visible.
-        if (viewParent == null) {
-            return false;
-        }
-
-        // If no portion of the parent is visible, this view is not visible.
-        if (!mView.getLocalVisibleRect(mTempVisibleRect)) {
-            return false;
-        }
-
-        // Check if the view intersects the visible portion of the parent.
-        return localRect.intersect(mTempVisibleRect);
-    }
-
-    /**
-     * Returns whether this virtual view is accessibility focused.
-     *
-     * @return True if the view is accessibility focused.
-     */
-    private boolean isAccessibilityFocused(int virtualViewId) {
-        return (mFocusedVirtualViewId == virtualViewId);
-    }
-
-    /**
-     * Attempts to give accessibility focus to a virtual view.
-     * <p>
-     * A virtual view will not actually take focus if
-     * {@link android.view.accessibility.AccessibilityManager#isEnabled()} returns false,
-     * {@link android.view.accessibility.AccessibilityManager#isTouchExplorationEnabled()} returns false,
-     * or the view already has accessibility focus.
-     *
-     * @param virtualViewId The id of the virtual view on which to place
-     *            accessibility focus.
-     * @return Whether this virtual view actually took accessibility focus.
-     */
-    private boolean requestAccessibilityFocus(int virtualViewId) {
-        final AccessibilityManager accessibilityManager =
-                (AccessibilityManager) mContext.getSystemService(Context.ACCESSIBILITY_SERVICE);
-
-        if (!mManager.isEnabled()
-                || !accessibilityManager.isTouchExplorationEnabled()) {
-            return false;
-        }
-        // TODO: Check virtual view visibility.
-        if (!isAccessibilityFocused(virtualViewId)) {
-            mFocusedVirtualViewId = virtualViewId;
-            // TODO: Only invalidate virtual view bounds.
-            mView.invalidate();
-            sendEventForVirtualView(virtualViewId,
-                    AccessibilityEvent.TYPE_VIEW_ACCESSIBILITY_FOCUSED);
-            return true;
-        }
-        return false;
-    }
-
-    /**
-     * Attempts to clear accessibility focus from a virtual view.
-     *
-     * @param virtualViewId The id of the virtual view from which to clear
-     *            accessibility focus.
-     * @return Whether this virtual view actually cleared accessibility focus.
-     */
-    private boolean clearAccessibilityFocus(int virtualViewId) {
-        if (isAccessibilityFocused(virtualViewId)) {
-            mFocusedVirtualViewId = INVALID_ID;
-            mView.invalidate();
-            sendEventForVirtualView(virtualViewId,
-                    AccessibilityEvent.TYPE_VIEW_ACCESSIBILITY_FOCUS_CLEARED);
-            return true;
-        }
-        return false;
-    }
-
-    /**
-     * Provides a mapping between view-relative coordinates and logical
-     * items.
-     *
-     * @param x The view-relative x coordinate
-     * @param y The view-relative y coordinate
-     * @return virtual view identifier for the logical item under
-     *         coordinates (x,y)
-     */
-    protected abstract int getVirtualViewAt(float x, float y);
-
-    /**
-     * Populates a list with the view's visible items. The ordering of items
-     * within {@code virtualViewIds} specifies order of accessibility focus
-     * traversal.
-     *
-     * @param virtualViewIds The list to populate with visible items
-     */
-    protected abstract void getVisibleVirtualViews(List<Integer> virtualViewIds);
-
-    /**
-     * Populates an {@link android.view.accessibility.AccessibilityEvent} with information about the
-     * specified item.
-     * <p>
-     * Implementations <b>must</b> populate the following required fields:
-     * <ul>
-     * <li>event text, see {@link android.view.accessibility.AccessibilityEvent#getText} or
-     * {@link android.view.accessibility.AccessibilityEvent#setContentDescription}
-     * </ul>
-     * <p>
-     * The helper class automatically populates the following fields with
-     * default values, but implementations may optionally override them:
-     * <ul>
-     * <li>item class name, set to android.view.View, see
-     * {@link android.view.accessibility.AccessibilityEvent#setClassName}
-     * </ul>
-     * <p>
-     * The following required fields are automatically populated by the
-     * helper class and may not be overridden:
-     * <ul>
-     * <li>package name, set to the package of the host view's
-     * {@link android.content.Context}, see {@link android.view.accessibility.AccessibilityEvent#setPackageName}
-     * <li>event source, set to the host view and virtual view identifier,
-     * see {@link android.view.accessibility.AccessibilityRecord#setSource(android.view.View, int)}
-     * </ul>
-     *
-     * @param virtualViewId The virtual view id for the item for which to
-     *            populate the event
-     * @param event The event to populate
-     */
-    protected abstract void onPopulateEventForVirtualView(
-            int virtualViewId, AccessibilityEvent event);
-
-    /**
-     * Populates an {@link android.view.accessibility.AccessibilityNodeInfo} with information
-     * about the specified item.
-     * <p>
-     * Implementations <b>must</b> populate the following required fields:
-     * <ul>
-     * <li>event text, see {@link android.view.accessibility.AccessibilityNodeInfo#setText} or
-     * {@link android.view.accessibility.AccessibilityNodeInfo#setContentDescription}
-     * <li>bounds in parent coordinates, see
-     * {@link android.view.accessibility.AccessibilityNodeInfo#setBoundsInParent}
-     * </ul>
-     * <p>
-     * The helper class automatically populates the following fields with
-     * default values, but implementations may optionally override them:
-     * <ul>
-     * <li>enabled state, set to true, see
-     * {@link android.view.accessibility.AccessibilityNodeInfo#setEnabled}
-     * <li>item class name, identical to the class name set by
-     * {@link #onPopulateEventForVirtualView}, see
-     * {@link android.view.accessibility.AccessibilityNodeInfo#setClassName}
-     * </ul>
-     * <p>
-     * The following required fields are automatically populated by the
-     * helper class and may not be overridden:
-     * <ul>
-     * <li>package name, identical to the package name set by
-     * {@link #onPopulateEventForVirtualView}, see
-     * {@link android.view.accessibility.AccessibilityNodeInfo#setPackageName}
-     * <li>node source, identical to the event source set in
-     * {@link #onPopulateEventForVirtualView}, see
-     * {@link android.view.accessibility.AccessibilityNodeInfo#setSource(android.view.View, int)}
-     * <li>parent view, set to the host view, see
-     * {@link android.view.accessibility.AccessibilityNodeInfo#setParent(android.view.View)}
-     * <li>visibility, computed based on parent-relative bounds, see
-     * {@link android.view.accessibility.AccessibilityNodeInfo#setVisibleToUser}
-     * <li>accessibility focus, computed based on internal helper state, see
-     * {@link android.view.accessibility.AccessibilityNodeInfo#setAccessibilityFocused}
-     * <li>bounds in screen coordinates, computed based on host view bounds,
-     * see {@link android.view.accessibility.AccessibilityNodeInfo#setBoundsInScreen}
-     * </ul>
-     * <p>
-     * Additionally, the helper class automatically handles accessibility
-     * focus management by adding the appropriate
-     * {@link android.view.accessibility.AccessibilityNodeInfo#ACTION_ACCESSIBILITY_FOCUS} or
-     * {@link android.view.accessibility.AccessibilityNodeInfo#ACTION_CLEAR_ACCESSIBILITY_FOCUS}
-     * action. Implementations must <b>never</b> manually add these actions.
-     * <p>
-     * The helper class also automatically modifies parent- and
-     * screen-relative bounds to reflect the portion of the item visible
-     * within its parent.
-     *
-     * @param virtualViewId The virtual view identifier of the item for
-     *            which to populate the node
-     * @param node The node to populate
-     */
-    protected abstract void onPopulateNodeForVirtualView(
-            int virtualViewId, AccessibilityNodeInfo node);
-
-    /**
-     * Performs the specified accessibility action on the item associated
-     * with the virtual view identifier. See
-     * {@link android.view.accessibility.AccessibilityNodeInfo#performAction(int, android.os.Bundle)} for
-     * more information.
-     * <p>
-     * Implementations <b>must</b> handle any actions added manually in
-     * {@link #onPopulateNodeForVirtualView}.
-     * <p>
-     * The helper class automatically handles focus management resulting
-     * from {@link android.view.accessibility.AccessibilityNodeInfo#ACTION_ACCESSIBILITY_FOCUS}
-     * and
-     * {@link android.view.accessibility.AccessibilityNodeInfo#ACTION_CLEAR_ACCESSIBILITY_FOCUS}
-     * actions.
-     *
-     * @param virtualViewId The virtual view identifier of the item on which
-     *            to perform the action
-     * @param action The accessibility action to perform
-     * @param arguments (Optional) A bundle with additional arguments, or
-     *            null
-     * @return true if the action was performed
-     */
-    protected abstract boolean onPerformActionForVirtualView(
-            int virtualViewId, int action, Bundle arguments);
-
-    /**
-     * Exposes a virtual view hierarchy to the accessibility framework. Only
-     * used in API 16+.
-     */
-    private class ExploreByTouchNodeProvider extends AccessibilityNodeProvider {
-        @Override
-        public AccessibilityNodeInfo createAccessibilityNodeInfo(int virtualViewId) {
-            return ExploreByTouchHelper.this.createNode(virtualViewId);
-        }
-
-        @Override
-        public boolean performAction(int virtualViewId, int action, Bundle arguments) {
-            return ExploreByTouchHelper.this.performAction(virtualViewId, action, arguments);
-        }
-    }
-}
diff --git a/tests/robotests/src/com/android/settings/connecteddevice/UsbModePreferenceControllerTest.java b/tests/robotests/src/com/android/settings/connecteddevice/UsbModePreferenceControllerTest.java
index da25f0f..8b6e900 100644
--- a/tests/robotests/src/com/android/settings/connecteddevice/UsbModePreferenceControllerTest.java
+++ b/tests/robotests/src/com/android/settings/connecteddevice/UsbModePreferenceControllerTest.java
@@ -113,7 +113,7 @@
         preference.setEnabled(true);
         mController.updateState(preference);
         assertThat(preference.getSummary()).isEqualTo(
-                mContext.getString(R.string.usb_nothing_connected));
+                mContext.getString(R.string.disconnected));
     }
 
     @Test
diff --git a/tests/robotests/src/com/android/settings/notification/WorkSoundPreferenceControllerTest.java b/tests/robotests/src/com/android/settings/notification/WorkSoundPreferenceControllerTest.java
index 13abd97..d996750 100644
--- a/tests/robotests/src/com/android/settings/notification/WorkSoundPreferenceControllerTest.java
+++ b/tests/robotests/src/com/android/settings/notification/WorkSoundPreferenceControllerTest.java
@@ -134,7 +134,6 @@
         mController.displayPreference(mScreen);
         verify(mWorkCategory).setVisible(false);
 
-
         // However, when a managed profile is added later, the category should appear.
         mController.onResume();
         when(mAudioHelper.getManagedProfileId(any(UserManager.class)))
@@ -204,6 +203,27 @@
     }
 
     @Test
+    public void onResume_noVoiceCapability_shouldHidePhoneRingtone() {
+        when(mTelephonyManager.isVoiceCapable()).thenReturn(false);
+        mController = new WorkSoundPreferenceController(mContext, mFragment, null, mAudioHelper);
+
+        when(mAudioHelper.getManagedProfileId(any(UserManager.class)))
+                .thenReturn(UserHandle.myUserId());
+        when(mAudioHelper.isUserUnlocked(any(UserManager.class), anyInt())).thenReturn(true);
+        when(mAudioHelper.isSingleVolume()).thenReturn(false);
+        when(mFragment.getPreferenceScreen()).thenReturn(mScreen);
+        when(mAudioHelper.createPackageContextAsUser(anyInt())).thenReturn(mContext);
+
+        // Precondition: work profile is available.
+        assertThat(mController.isAvailable()).isTrue();
+
+        mController.displayPreference(mScreen);
+        mController.onResume();
+
+        verify(mWorkCategory.findPreference(KEY_WORK_PHONE_RINGTONE)).setVisible(false);
+    }
+
+    @Test
     public void onResume_availableButLocked_shouldRedactPreferences() {
         final String notAvailable = "(not available)";
         when(mContext.getString(R.string.managed_profile_not_available_label))
diff --git a/tests/robotests/src/com/android/settings/search/XmlParserUtilTest.java b/tests/robotests/src/com/android/settings/search/XmlParserUtilTest.java
index 028cbb0..5b7efcd 100644
--- a/tests/robotests/src/com/android/settings/search/XmlParserUtilTest.java
+++ b/tests/robotests/src/com/android/settings/search/XmlParserUtilTest.java
@@ -56,7 +56,7 @@
 
     @Test
     public void testDataTitleValid_ReturnsPreferenceTitle() {
-        XmlResourceParser parser = getChildByType(R.xml.ia_display_settings,
+        XmlResourceParser parser = getChildByType(R.xml.display_settings,
                 "com.android.settings.TimeoutListPreference");
         final AttributeSet attrs = Xml.asAttributeSet(parser);
         String title = XmlParserUtils.getDataTitle(mContext, attrs);
@@ -66,7 +66,7 @@
 
     @Test
     public void testDataKeywordsValid_ReturnsPreferenceKeywords() {
-        XmlResourceParser parser = getParentPrimedParser(R.xml.ia_display_settings);
+        XmlResourceParser parser = getParentPrimedParser(R.xml.display_settings);
         final AttributeSet attrs = Xml.asAttributeSet(parser);
         String keywords = XmlParserUtils.getDataKeywords(mContext, attrs);
         String expKeywords = mContext.getString(R.string.keywords_display);
@@ -75,7 +75,7 @@
 
     @Test
     public void testDataKeyValid_ReturnsPreferenceKey() {
-        XmlResourceParser parser = getChildByType(R.xml.ia_display_settings,
+        XmlResourceParser parser = getChildByType(R.xml.display_settings,
                 "com.android.settings.TimeoutListPreference");
         final AttributeSet attrs = Xml.asAttributeSet(parser);
         String key = XmlParserUtils.getDataKey(mContext, attrs);
@@ -85,7 +85,7 @@
 
     @Test
     public void testDataSummaryValid_ReturnsPreferenceSummary() {
-        XmlResourceParser parser = getChildByType(R.xml.ia_display_settings,
+        XmlResourceParser parser = getChildByType(R.xml.display_settings,
                 "com.android.settings.TimeoutListPreference");
         final AttributeSet attrs = Xml.asAttributeSet(parser);
         String summary = XmlParserUtils.getDataSummary(mContext, attrs);
@@ -128,7 +128,7 @@
 
     @Test
     public void testDataKeyInvalid_ReturnsNull() {
-        XmlResourceParser parser = getParentPrimedParser(R.xml.ia_display_settings);
+        XmlResourceParser parser = getParentPrimedParser(R.xml.display_settings);
         final AttributeSet attrs = Xml.asAttributeSet(parser);
         String key = XmlParserUtils.getDataKey(mContext, attrs);
         assertThat(key).isNull();
@@ -136,7 +136,7 @@
 
     @Test
     public void testDataSummaryInvalid_ReturnsNull() {
-        XmlResourceParser parser = getParentPrimedParser(R.xml.ia_display_settings);
+        XmlResourceParser parser = getParentPrimedParser(R.xml.display_settings);
         final AttributeSet attrs = Xml.asAttributeSet(parser);
         String summary = XmlParserUtils.getDataSummary(mContext, attrs);
         assertThat(summary).isNull();
@@ -144,7 +144,7 @@
 
     @Test
     public void testDataSummaryOffInvalid_ReturnsNull() {
-        XmlResourceParser parser = getParentPrimedParser(R.xml.ia_display_settings);
+        XmlResourceParser parser = getParentPrimedParser(R.xml.display_settings);
         final AttributeSet attrs = Xml.asAttributeSet(parser);
         String summaryOff = XmlParserUtils.getDataSummaryOff(mContext, attrs);
         assertThat(summaryOff).isNull();
@@ -152,7 +152,7 @@
 
     @Test
     public void testDataEntriesInvalid_ReturnsNull() {
-        XmlResourceParser parser = getParentPrimedParser(R.xml.ia_display_settings);
+        XmlResourceParser parser = getParentPrimedParser(R.xml.display_settings);
         final AttributeSet attrs = Xml.asAttributeSet(parser);
         String entries = XmlParserUtils.getDataEntries(mContext, attrs);
         assertThat(entries).isNull();
diff --git a/tests/robotests/src/com/android/settings/search2/DatabaseIndexingManagerTest.java b/tests/robotests/src/com/android/settings/search2/DatabaseIndexingManagerTest.java
index d537bc9..7d611c6 100644
--- a/tests/robotests/src/com/android/settings/search2/DatabaseIndexingManagerTest.java
+++ b/tests/robotests/src/com/android/settings/search2/DatabaseIndexingManagerTest.java
@@ -49,7 +49,6 @@
 import org.mockito.MockitoAnnotations;
 import org.robolectric.RuntimeEnvironment;
 import org.robolectric.annotation.Config;
-import org.robolectric.shadows.ShadowApplication;
 import org.robolectric.shadows.ShadowContentResolver;
 
 import java.util.ArrayList;
@@ -248,7 +247,7 @@
 
     @Test
     public void testAddResource_RowsInserted() {
-        SearchIndexableResource resource = getFakeResource(R.xml.ia_display_settings);
+        SearchIndexableResource resource = getFakeResource(R.xml.display_settings);
         mManager.indexOneSearchIndexableData(mDb, localeStr, resource, new HashMap<>());
         Cursor cursor = mDb.rawQuery("SELECT * FROM prefs_index", null);
         assertThat(cursor.getCount()).isEqualTo(16);
@@ -256,7 +255,7 @@
 
     @Test
     public void testAddResource_withNIKs_rowsInsertedDisabled() {
-        SearchIndexableResource resource = getFakeResource(R.xml.ia_display_settings);
+        SearchIndexableResource resource = getFakeResource(R.xml.display_settings);
         // Only add 2 of 16 items to be disabled.
         String[] keys = {"brightness", "wallpaper"};
         Map<String, Set<String>> niks = getNonIndexableKeys(keys);
diff --git a/tests/unit/Android.mk b/tests/unit/Android.mk
index f98fccd..f9c0489 100644
--- a/tests/unit/Android.mk
+++ b/tests/unit/Android.mk
@@ -18,6 +18,7 @@
 LOCAL_SRC_FILES := $(call all-java-files-under, src)
 
 LOCAL_PACKAGE_NAME := SettingsUnitTests
+LOCAL_COMPATIBILITY_SUITE := device-tests
 
 LOCAL_INSTRUMENTATION_FOR := Settings